This finds unused dependencies in your node project.
npm install -g depscan
- go to target dir and run
- You can also scan multiple entry points by doing
depscan ../source1.js ../source2.js
Output looks like this:
These dependencies are not used: imap mailparser mail-listener2 mailstrip These dependencies are missing in package.json: msgpack policyfile
var depscan = ;var scan = ;var report = scan;console;
report is an object like this:
unused: 'foo'missing: 'bar''baz'