By default, npm references package version numbers with the caret (^) character when installing a package with –save or –save-dev
1
2
3
4
5
npm shrinkwrap
# generates an npm-shrinkwrap.json file. This allows you to pin the dependencies of your project to the specific version you’re currently using within your node_modules directory.
npm config set save-prefix="~"
npm config set save-exact true
Outdated Paketler
1
2
3
4
npm outdated
# examine the current and historical versions:
npm view <package> versions
Güncellemeler
1
2
3
4
npm install -g npm
# You may also need to rebuild C++ addons when a new major version of Node is released
npm rebuild
Muhtelif
npm run foo will also run prefoo and postfoo if you have them
You can install GitHub repos with npm i org-name/repo-name