问题
I'm integrating RequireJS and AngularJS. This is fairly complex problem and I'm struggling to articulate my problem in a Stackoverflow post, so here is a screencast of my issue. Sit back, relax, watch the weirdness..
http://goo.gl/02CGVe
Basically when I load my core dependencies with RequireJS Angular seems to compile the page and then my elements dissapear off the page. I'm at a loss. Any help would be greatly appreciated!
Sidenote: I'm not building a SPA, so there is no need for ngRoute in my case. Here's one of the many tuts that discuss (kinda) what I'm trying to do.
回答1:
Actually, refer to this Stackoverflow question about an effective way of using AngularJS with RequireJS.
Does AngularJS support AMD like RequireJS?
I saw you video and found some inconsistencies and also, the way you hooked AngularJS with RequireJS is not ideal and kind of confusing. Refer to my post about hooking up both libraries in a consistent and effective way.
http://leog.me/log/large-angularjs-app-components
Hope it helps.
来源:https://stackoverflow.com/questions/26056502/requirejs-and-angularjs