devDependencies
Packages listed in package.json that are needed only to build or test the app, such as TypeScript or a test runner.
In more detail
They are installed during development and builds but are not needed to run the finished app. Leaving them out of production images makes those images smaller and safer.
Example
The Next.js builder stage needs them for next build; the runner stage does not.Related terms
- package.json — The JSON file at the root of every JavaScript package that records its name, version, dependencies, entry points and other settings.
- multi-stage build — A Dockerfile with several FROM stages, where later stages copy only what they need from earlier ones.
Taught in
- Containerized Deployment: Multi-Stage Docker Builds — Next.js 15 & Modern App Router Architecture