Created
July 13, 2018 05:54
-
-
Save devarajchidambaram/e0520177cfb36069bc769378867642ed to your computer and use it in GitHub Desktop.
SET environment variable in NODEJS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NODE_ENV works like any other environment variable (e.g. PATH) and it depends on your platform how to set it: | |
Linux and OSX: export NODE_ENV=production | |
Windows: SET NODE_ENV=production | |
In nodejs app we can get it | |
process.env.NODE_ENV |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment