Locking modules to specific versions

suggest change

npm installs the newest version that satisfies each dependency's semantic version range. A later publish inside that range can still change what a fresh install gets.

Since npm 5, a normal install writes package-lock.json, which records the exact tree. npm shrinkwrap writes npm-shrinkwrap.json instead. That file is meant to be published with a library and, when both exist, it takes precedence over package-lock.json for people who install the package.

npm shrinkwrap

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents