Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我已经创建了一个新项目,现在我很难理解如何正确集成一个新的节点模块(lodash)。我已经安装了节点模块npm install lodash --save,我看到它已将其添加到 package.json 文件中,并且资产位于根 node_modules 文件夹中。
npm install lodash --save
我如何在我的项目中实际使用它?
您无需安装即可使用 lodash。因为 mean.io 的核心部分已经使用了 lodash。
如果你的意思是你自己的包,你可以npm install在你的包目录中(带有自己的 package.json)。每次其他人是mean install您的软件包时,它都会安装所有模块。
npm install
mean install