My provider code is as follows:
(function (angular) {
var listing_app = angular.module('TEST.Providers', []);
listing_app.provider('TESTAdapter', ['$filter',function ($filter) {
var self = this;
this.$get = function () {
return {
"convert": function (result) {
//do something
return result;
}
};
};
}]);
})(angular);
However, I encountered the error message: Error: [$injector:unpr] Unknown provider: $filter. I am puzzled by why we are unable to inject $filter in the provider.