I have set some environment variables in the UI.
I am trying to use them in my code like this:
console.log("AUTH0_DOMAIN:"); console.log(process.env.AUTH0_DOMAIN); console.log("AUTH0_CLIENT_ID:"); console.log(process.env.AUTH0_CLIENT_ID); console.log("AUTH0_AUDIENCE:"); console.log(process.env.AUTH0_AUDIENCE);
When starting up the local dev server using “ntl dev” it looks like the environment variables are being injected:
But they all come through as
undefined as shown here in the console:
So what am I doing wrong?
Why are they coming through as undefined?