The JavaScript ecosystem.
WHAT A PACKAGE MANAGER DOES
Installs libraries and records exact versions.
WHAT TO COMMIT
The declaration of what you require, and the lock file recording what was installed.
WHY THE LOCK FILE
It guarantees identical versions everywhere.
WHAT NOT TO COMMIT
The installed dependencies directory.
WHAT A BUNDLER DOES
Combines modules into files the browser loads efficiently, and applies transformations.
WHY IT IS NEEDED
Modern code uses features and structures that benefit from processing before delivery.
WHAT ELSE BUILD TOOLING DOES
Compiles newer syntax for older browsers Removes unused code Minifies output Adds version identifiers to filenames
WHY THAT LAST ONE
So caching does not serve an old file after a change.
WHAT TO BE CAREFUL WITH
Dependencies added casually, each bringing its own Very large bundles Build configuration nobody understands
WHAT TO CHECK
The size of what you ship.
WHY
Every added library is downloaded, parsed and executed by every visitor.
WHAT TO REMOVE
Anything unused.