A package manager is a tool that automates installing, updating, and managing third-party code libraries (packages) your project depends on. For vibe coders, package managers like npm, bun, and pnpm are how you add functionality — when AI says 'install stripe', the package manager handles it.
Package managers are the unsung heroes of modern development. They let you stand on the shoulders of thousands of open-source contributors.
| Manager | Command | Speed | Notes |
|---|---|---|---|
| npm | npm install | Standard | Comes with Node.js |
| bun | bun install | Fastest | Modern, all-in-one toolkit |
| pnpm | pnpm install | Fast | Efficient disk usage |
| yarn | yarn add | Fast | Facebook-created alternative |
package.jsonnpm run dev or npm run buildnpm install # Install all dependencies
npm install stripe # Add a new package
npm run dev # Start development server
npm run build # Build for production
npm update # Update packages
When AI generates code that imports a library you don't have, you'll need to install it. AI usually tells you which packages to install — just run the command in your terminal.