简体   繁体   English

我应该把bower.json放在哪里?

[英]Where should I put bower.json?

So, I'm using bower 1.2.2 to manage my client side libraries for the first time. 所以,我第一次使用bower 1.2.2来管理我的客户端库。 My app is a simple node app, and I can't decide where to initialize bower. 我的应用程序是一个简单的节点应用程序,我无法决定在哪里初始化bower。 Here's my file structure: 这是我的文件结构:

|____gruntfile.js
|____package.json
|____server.js
|____static
| |____index.html

Should I initialize bower in the root next to gruntfile.js and package.json, or should I do it in my static directory. 我应该在gruntfile.js和package.json旁边的根目录中初始化bower,还是应该在我的静态目录中执行此操作。 Any advice is greatly appreciated! 任何意见是极大的赞赏!

IMHO you can have that on the root where other tasks files are added. 恕我直言,你可以在添加其他任务文件的根目录。 This way your bower_components will also reside on the root folder along with node_modules. 这样,您的bower_components也将与node_modules一起驻留在根文件夹中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM