[英]Tried to load angular more than once + included the Google Maps API multiple times on this page
每当我按网站上的“开始使用”按钮时,屏幕就会变黑,并且控制台日志中出现以下错误。 在运行grunt build
并将其部署到Heroku之前,我没有在本地看到此问题:
WARNING: Tried to load angular more than once.
You have included the Google Maps API multiple times on this page. This may cause unexpected errors.
我的index.html的代码如下,完整代码在这里 :
<script src="https://maps.googleapis.com/maps/api/js?libraries=places&key=AIzaSyBHuxIv-E8l4YRp_vWjW7X22gRNwI1xN30"></script>
<!-- build:js(.) scripts/vendor.js -->
<!-- bower:js -->
<script src="bower_components/jquery/dist/jquery.js"></script>
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/bootstrap-sass-official/assets/javascripts/bootstrap.js"></script>
<script src="bower_components/angular-animate/angular-animate.js"></script>
<script src="bower_components/angular-cookies/angular-cookies.js"></script>
<script src="bower_components/angular-resource/angular-resource.js"></script>
<script src="bower_components/angular-route/angular-route.js"></script>
<script src="bower_components/angular-sanitize/angular-sanitize.js"></script>
<script src="bower_components/angular-touch/angular-touch.js"></script>
<script src="bower_components/ngstorage/ngStorage.js"></script>
<script src="bower_components/moment/moment.js"></script>
<script src="bower_components/angular-moment/angular-moment.js"></script>
<script src="bower_components/angular-strap/dist/angular-strap.js"></script>
<script src="bower_components/angular-strap/dist/angular-strap.tpl.js"></script>
<script src="bower_components/angular-modal-service/dst/angular-modal-service.js"></script>
<script src="bower_components/vsGoogleAutocomplete/dist/vs-google-autocomplete.js"></script>
<script src="bower_components/vsGoogleAutocomplete/dist/vs-autocomplete-validator.js"></script>
<!-- endbower -->
<!-- endbuild -->
不知道还有什么可能导致此问题? 有人可以帮忙吗?
更新
我还包括了Grunt任务: https : //pastebin.com/3JiaQwXU 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.