package-lock.json
文件中的"dev"true
意味着什么?
就我而言,当我执行 npm
操作时,它会自动更新。
我们如何删除它?
最佳答案
所以回答你的第一个问题,package-lock.json
中的"dev": true
意味着这个依赖项不会被npm install
安装code>/npm ci
在生产
模式下运行时。
仅将依赖项用于标记有 "dev": true
的本地开发环境,然后在 CI 中使用 --product
可能会节省一些构建时间。
来自文档 https://docs.npmjs.com/cli/install#description :
By default,
npm install
will install all modules listed as dependencies inpackage.json
.With the
--production
flag (or when theNODE_ENV
environment variable is set toproduction
), npm will not install modules listed indevDependencies
.
关于npm - package-lock.json 中的 `"dev"true` 是做什么用的?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49809490/