I'm working on a web application using AngularJS. Everything seemed to work well until I tried to run it with Microsoft Edge web-browser:
Error: [$injector:unpr] Unknown provider: serviceAjaxProvider <- serviceAjax <- MainCtrl
I created a service, called serviceAjax and never had any problem with it on Chrome or Firefox. But now that I'm trying to use my app on Edge I got this error.
My service is declared as the following :
serviceAjax.js
angular.module('myApp')
.service('serviceAjax', ['$http', function ($http) {
...
}]);
And I call it like this in my controller :
main.js
angular.module('myApp')
.controller('MainCtrl', function ($scope,serviceAjax) {
...
});
Where does this error come from, and how can I fix it ?