简体   繁体   中英

AngularJS + JQuery = TypeError: Cannot read property 'then' of undefined

Trying to debug a JS issue, but not having any success - trace is below.

TypeError: Cannot read property 'then' of undefined    
    at Object.fn (angular.min.js:937)
    at l.$get.l.$digest (angular.min.js:508)
    at l.$get.l.$apply (angular.min.js:522)
    at HTMLLIElement.<anonymous> (angular.min.js:928)
    at HTMLLIElement.x.event.dispatch (jquery-1.11.0.min.js:10)
    at HTMLLIElement.x.event.add.v.handle (jquery-1.11.0.min.js:10)

Issue is that the code generating the error does not include 'then' - I'm removing objects from an array, the error throws when the last object is removed but the app continues to function correctly. Wondering if it's just an internal Angular error that I can ignore?

How can I better trace the cause?

更新了ngAnimate模块,问题消失了。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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