Skip to content
This repository has been archived by the owner on Sep 4, 2020. It is now read-only.

grommet pack does not consider .env file contents #58

Open
thg303 opened this issue Apr 17, 2020 · 1 comment
Open

grommet pack does not consider .env file contents #58

thg303 opened this issue Apr 17, 2020 · 1 comment

Comments

@thg303
Copy link

thg303 commented Apr 17, 2020

how to reproduce:

  1. build a new project.
  2. create a .env file and set a variable in it like:
PORT=5050
  1. run npm run dev
    it serves it on the default port (3000).

the expected behaviour is serving the app on http://localhost:5050

@thg303
Copy link
Author

thg303 commented Apr 17, 2020

looks like babel puts imports statements above 'require`s so the pack scrip loads before dotenv has any chance to load the .env file.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant