Node

npm Commands You're Probably Not Using

Most developers know npm install, npm run, and npm publish. The rest of the CLI tends to be discovered only when something breaks — which is the worst possible time to learn a debugging tool.

These are the commands I’ve found myself reaching for repeatedly, in rough order of how often they actually come up.


npm explain

This one earns its place every time a dependency audit or lockfile conflict appears. npm explain traces why a package is in your node_modules — which package required it, and what required that.

Read more →