Skip to content

Access environment variable #3

@lorrod

Description

@lorrod

Hello!
Could you please help to solve the issue with getting environment variable?
I have tried to access via:

process.env.VARIABLE_NAME

but it seems that webpack is not configured to pass process variable, am I right? I am getting Can't find variable: process

Also I have tried to pass environment variable using web pack with no luck:

new webpack.DefinePlugin({
  'process.env.API_BASE_URL': JSON.stringify('https://api.example.com'),
})

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions