Is there a way to inject $q into provider, in my case, angular throws exception telling that there is no such provider.
For a provider, the values are injected in the $get function.
myApp.provider('testProvider', function() {
this.$get = function($q) {
};
});
More details here:
AngularJS: Service vs provider vs factory
https://gist.github.com/Mithrandir0x/3639232
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With