Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

236
Views
Cannot access environment variable in desired file

I am trying to access environment variables in my Display.js, I have created a .env file in the root of my project, however, process.env is not logging my env variable.

.env inside of root folder of my project:

https://i.stack.imgur.com/WaKMQ.png

Display.js (located in same folder as .env):

https://i.stack.imgur.com/MJG80.png

Image of my folders:

https://i.stack.imgur.com/IlAsZ.png

about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

.env must be located of project root directory

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!