美文网首页
npm install --save-dev xxx 和 n

npm install --save-dev xxx 和 n

作者: 喵啊楞 | 来源:发表于2017-09-26 16:21 被阅读0次

当我们在用npm安装插件或者模块时,常常用到npm install --save -dev xxx的方法,这种方式安装,会将这个插件写到package.json文件夹中的devDependencies字段当中,这种方式适用于开发环境;而使用--save的方式,则将其写到dependencies的字段当中,这种方式则适用于生产环境。

相关文章

网友评论

      本文标题:npm install --save-dev xxx 和 n

      本文链接:https://www.haomeiwen.com/subject/kxosextx.html