5 Quick NodeJS tips
1 min readDec 14, 2019
1. Settings
Always keep settings in a config/settings module, this way if you change the way you read them, you just change this single module
2. Is module run as require or directly?
You can have a module that is both available as part of the commandline and can be required as well
3. Update NPM
npm i npm -g
— nuff said.
4. NPM Shrinkwrap
To lock down all npm package versions, so when someone runs npm install
everyone will have the exact same version, you can use
npm shrinkwrap
5. NPM home
npm home {packageName}
can be used to open the homepage of a package.