I am new to angularjs.
I am trying to build a mobile application inspired from modular approach defined here:
http://thaiat.github.io/blog/2014/02/26/angularjs-and-requirejs-for-very-large-applications/
Now I am trying to create a service using factory method in one of my modules core
. I have another module called home
. Now when I try to inject service from core
to home
, I get an error:
Error: [$injector:unpr] Unknown provider: glue.core.geoLocationServiceProvider <- glue.core.geoLocationService
I have searched through internet and here. None of the solutions are working for me.
the code of my home
module's controller
is:
define([
'../module',
'../namespace',
],
function(module, namespace) {
'use strict';
var name = namespace + ".homeController";
var dependencies = ['$scope', '$http', '$ionicLoading', 'glue.core.geoLocationService'];
var controller = function($scope, $http, $ionicLoading, core) {
}
module.controller(name, dependencies.concat(controller));
});
I have also uploaded the project here on github: https://github.com/neerajsohal/test/tree/development
Any help would be great. I am going mad with this.