I am trying to integrate http-auth-interceptor into mean.io (express / angular), but keep receiving the following error:
Error: [$injector:modulerr] Failed to instantiate module mean due to:
Error: [$injector:modulerr] Failed to instantiate module http-auth-interceptor due to:
Error: [$injector:nomod] Module 'http-auth-interceptor' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.
I am using AngularJS 1.2.4 and I have http-auth-interceptor.js located in /public/lib/http-auth-interceptor/http-auth-interceptor.js
This is what my app.js looks like
angular.module('mean', [
'http-auth-interceptor',
'ngCookies',
'ngResource',
'ngRoute',
'ui.bootstrap',
'ui.route',
'mean.system',
'mean.articles',
'login'])
/**
* This directive will find itself inside HTML as a class,
* and will remove that class, so CSS will remove loading image and show app content.
* It is also responsible for showing/hiding login form.
*/
.directive('meanApplication', function() {
return {
restrict: 'C',
link: function(scope, elem, attrs) {
//once Angular is started, remove class:
elem.removeClass('waiting-for-angular');
var login = elem.find('#login-holder');
var main = elem.find('#content');
login.hide();
scope.$on('event:auth-loginRequired', function() {
login.slideDown('slow', function() {
main.hide();
});
});
scope.$on('event:auth-loginConfirmed', function() {
main.show();
login.slideUp();
});
}
};
});
angular.module('mean.system', []);
angular.module('mean.articles', []);
angular.module('login', []);
When the page is loaded I am able to click on and open http-auth-interceptor.js from view-source. I know I am missing something obvious, please let me know if you need any more information.
I am trying to integrate http-auth-interceptor into mean.io (express / angular), but keep receiving the following error:
I am using AngularJS 1.2.4 and I have http-auth-interceptor.js located in /public/lib/http-auth-interceptor/http-auth-interceptor.js
This is what my app.js looks like
And my login.js controller looks like this:
And I am loading http-auth-interceptor.js in the footer like this:
When the page is loaded I am able to click on and open http-auth-interceptor.js from view-source. I know I am missing something obvious, please let me know if you need any more information.
Thanks, DH