Angular-animate - 未知提供者:$$asyncCallbackProvider <- $$asyncCallback <- $animate <- $compile [英] Angular-animate - Unknown provider: $$asyncCallbackProvider <- $$asyncCallback <- $animate <- $compile

查看:20
本文介绍了Angular-animate - 未知提供者:$$asyncCallbackProvider <- $$asyncCallback <- $animate <- $compile的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个奇怪的问题.我想在我的 AngularJS 项目中包含 angular-animate - 我使用的是 AngularJS v1.2.6.我已将 angular-animate 添加到我的凉亭文件中.它已经下载并添加到我的源代码中的 HTML 文件中,并且指向正确的文件(它在浏览器中加载).现在我需要将其添加为依赖项,因此我将模块添加到我的应用程序中...

I have a strange issue. I want to include angular-animate in my AngularJS project - I am using AngularJS v1.2.6. I have added angular-animate to my bower file. It has downloaded and added to my HTML file in the source and it is pointing to the correct file (it loads in the browser). Now I need to add this as a dependancy, so I add the module to my app...

angular.module('myApp', [
        'ngResource',
        'ngSanitize',
        'ngRoute',
        'ui.bootstrap',
        'LocalStorageModule',
        'cookiesModule',
        'ngAnimate'
    ])  

但是,一旦 Grunt 开始检测文件更改并构建,我就会收到以下错误:

However as soon as Grunt kicks in detecting a file change and builds I get the following error:

Unknown provider: $$asyncCallbackProvider <- $$asyncCallback <- $animate <- $compile

我检查了拼写,我已经按照 https://github.com/angular/上提到的说明进行操作bower-angular-animate 但我不明白为什么这不起作用或为什么我收到错误!我已经更改了依赖项数组中依赖项的位置,但这没有任何作用.有没有其他人经历过这种情况?我会继续研究这个,但如果有人克服或确定了为什么会发生这种情况,请说出来!提前致谢

I've check the spelling, I've followed the instructions mentioned on https://github.com/angular/bower-angular-animate but I can't see why this isn't working or why I am getting the error! I've change the position of the dependency in the dependency array but this does nothing. Has anyone else experienced this? I'll continue researching this but if anyone has overcome or determined why this is happening please speak up! Thanks in advance

推荐答案

呸!我想我已经解决了这个问题... Bower 似乎是问题和解决方案!

Phew! I think I have fixed this... Bower seems to be the issue and solution!

我在我的凉亭文件中从 AngularJS 1.2.6 更改为 1.2.15,这解决了我的问题:

I change from AngularJS 1.2.6 to 1.2.15 in my bower file and this resolved my issue:

所以我改变了这个:

  "angular": "1.2.6"

到这里

  "angular": "1.2.15"

好吧,那只花了我 2 小时!

Well, That only cost me 2 hours!

这篇关于Angular-animate - 未知提供者:$$asyncCallbackProvider &lt;- $$asyncCallback &lt;- $animate &lt;- $compile的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆