You're correct. npm ci also installs dev dependencies.
npm ci
Adding --only=prod or --production would not install devDependencies and just install dependencies.
--only=prod
--production
devDependencies
dependencies
I'll update the article to show both options 👍
It's now recommended to use --omit=dev over --production 😆 Good ole Node.js.
--omit=dev
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
You're correct.
npm ci
also installs dev dependencies.Adding
--only=prod
or--production
would not installdevDependencies
and just installdependencies
.I'll update the article to show both options 👍
It's now recommended to use
--omit=dev
over--production
😆 Good ole Node.js.