1

I'm trying to access the environment variables in my React App, however they aren't registering.

console.log(process.env)

enter image description here

All of my variables are in a file named .env.development.local, and are prefixed with REACT_APP_

REACT_APP_API_KEY_IF=XXXX
REACT_APP_API_KEY_MAPFLIGHT=XXXX
REACT_APP_SESSION_ID=XXXX

What could I be doing wrong here? Thanks

1 Answer 1

2

Alright so it looks like I was supposed to restart the server after adding new Variables, that did it.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.