I spent last week's article checking whether any package registry tells you, before you
install something, that it's going to run code on your machine. This week I got stuck on a
dumber, more basic question: how much stuff , period, am I actually getting? Not "is it
dangerous," just "how big is the invisible part."
Everyone has an opinion on this. "node_modules is a black hole." "lodash is bloated." "is-even
depends on is-odd depends on half the left-pad universe." I've repeated all three myself. None
of them are things I'd actually measured. So I wrote a small script that walks a package
registry's own public JSON — no npm install , no npm ls , no lockfile, nothing downloaded
except the metadata itself — and counts.
The two that surprised me most
lodash has a reputation as the kitchen-sink utility library everyone complains about pulling
into a project "just for one function." Its own registry entry, v4.18.1 , lists zero
runtime dependencies. Zero.…