marcoslin / angularAMD

Facilitate use of RequireJS in AngularJS
http://marcoslin.github.io/angularAMD
MIT License
734 stars 171 forks source link

$httpProvider.interceptors #96

Closed hawkwind2 closed 9 years ago

hawkwind2 commented 9 years ago

Another one please, how do I use that code in AMD? When we have $routeProvider...

app.config(function ($httpProvider) { $httpProvider.interceptors.push('authInterceptorService'); });

marcoslin commented 9 years ago

That should work.

angular-moon commented 9 years ago

动态加载的模块里的 app.config(function ($httpProvider) { $httpProvider.interceptors.push('authInterceptorService'); }); 拦截器没有执行

marcoslin commented 9 years ago

@angular-moon app.config must be ran before calling angularAMD.bootstrap for it to work.