angularjs - Injection error while injecting scope in custom filter definition -
i trying inject $scope variable in angularjs custom filter definition.
the javascript code looks this:
angular.module('myapp',[]) .filter("myfilter", ['$scope', myfilterfunction]) function myfilterfunction($scope){ return function(client){ return client.tolowercase(); } } but way not working due injection error. there better way achieve trying here.
Comments
Post a Comment