Skip to content

Latest commit

 

History

History
8 lines (6 loc) · 716 Bytes

File metadata and controls

8 lines (6 loc) · 716 Bytes

Frequently Asked Questions

NODE_ENV observations

  • We use the NODE_ENV environment variable to drive some logic in our code (like logging levels)
  • The NODE_ENV variables is also used to configure NPM - the default package manager for javascript. (It's not an acronym for Node Package Manager :)
    • If NODE_ENV=production, npm will only install production dependencies, dev-dependencies are omitted.
    • If you have NODE_ENV=production, do an npm install and then npm test or npm run dev they will usually fail, because modules needed for testing and development will be installed as dev-dependencies.