I'm trying to use environment variables in my react app that I created with npx create-react-app. I created.env file(in the root directory) and placed the variable which start with REACT_APP, but still when I try to log it in the console, it shows up undefined.
I did restart development server many times, still the same.
I uploaded test project here
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.