我使用lodash安装了angularjs应用程序:
bower install --save lodash相应地更新bower.json:
{
"name": "my-app",
"version": "0.0.0",
"dependencies": {
"lodash": "^4.11.2",
"angular": "~1.4.0",
"json3": "~3.2.4",
"jquery": "~1.10.0",
"sass-bootstrap": "~3.0.0",
"es5-shim": "~2.1.0",
"angular-resource": "~1.4.0",
"angular-cookies": "~1.4.0",
"angular-sanitize": "~1.4.0",
"angular-route": "~1.4.0",
"angular-ui": "~0.4.0"
},
"devDependencies": {
"angular-mocks": "~1.4.0",
"angular-scenario": "~1.4.0"
}
}lodash目录被添加到bower_components目录中,我运行了grunt server。但是,<script>标记没有添加到index.html中。
在我的应用程序安装了bower之后,如何将lodash添加到应用程序中呢?FWIW,我已经成功地安装了其他前端组件,并且没有遇到这个问题,所以要么我正在做一些不同的事情,要么我的环境发生了变化。
我不知道该如何调查这个问题。
发布于 2016-05-07 13:00:06
您需要手动执行或使用咕噜咕噜任务。如果您的应用程序已经配置了wiredep任务,那么只需运行grunt wiredep即可。
https://stackoverflow.com/questions/37088637
复制相似问题