jargon

Frontend & browser·Modules, bundling and the build

you import one function from a library and the other two hundred never reach the bundle.

Tree shaking

Also calledlive code inclusion

Dropping exports that are never imported, using the static structure of ES modules to prove nothing references them. It works far less often than people assume: a CommonJS build, a re-export barrel, or a module the bundler cannot prove is side-effect free will all keep everything. Checking the analyser rather than trusting the term is the difference between an optimisation and a belief.

Commonly confused with