Sign Up
Go Pro Sign Up Login

Buy Now and unlock this series

$

49

.99

$

29

.99

yours forever

Become a Pro and unlock everything

$

24

.99

per month

Dot ENV

Before we go any further, we will take a minute to set up dot ENV support in our app. This is important if we want to share secrets and keys but keep the values hidden from the public. npm install —save dotenv

Downloads

Become a pro to download code and videos

Comments

Hartwig

about 1 month ago [edited]

On windows 10.

in env.js just add an object with path: 'src/.env In fact, the dotenv will work just as here. Trying to make use of the preloading does not make the trick. It is just so that the library, at least on windows does use this additional path info.

--> dotenv.config( { path: 'src/.env' } )

Cheers

Want to join the conversation?

Become a Pro member today!