Created
October 7, 2021 00:33
-
-
Save italosantana/c69e0f5ac270d1bac36f3fe7a075b3cc to your computer and use it in GitHub Desktop.
Setting environment variables package.json
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
| Make it cross-platform by using cross-env: | |
| "server": "cross-env SERVERPORT=3002 node ./fiboserver" | |
| Linux | |
| "scripts": { | |
| "dev:linux": "NODE_ENV=development node foo.js" | |
| } | |
| Windows 10 | |
| "scripts": { | |
| "start": "SET NODE_ENV=development & nodemon app/app.js", | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment