So I\'ve been trying a while to make a custom filter that searches for the \'Startswith\' parameters rather than the \'Contains\'. Every filter that I\'ve written haven\'t s
A simple way to do this is to add a new method to your scope.
$scope.startsWith = function (actual, expected) {
var lowerStr = (actual + "").toLowerCase();
return lowerStr.indexOf(expected.toLowerCase()) === 0;
}
Then change the filter syntax on your element.
Here is a working plunkr with the example above.