NPM install configurations
- Install package without updating
package.json
npm install <package name> --no-save
- Install package and update
dependencies
inpackage.json
(default)
npm install <package name> --save
- Install package and update
devDependencies
inpackage.json
npm install <package name> --save-dev
- Install package and update
optionalDependencies
inpackage.json
npm install <package name> --save-optional
Note
Dev dependencies are packages needed by the project in the dev environment and not in the production environment