Why won't angular display values that are null when I apply:
ng-repeat="p in foo | filter: filter2"
where filter2 is
$scope.filter2 = function(p){
if (p.state === null){
return p.state;
} else{
return;
}
};
here's a plnkr with what I'm saying: http://plnkr.co/edit/cj3v1fuBu6sHVI7A4qlq?p=preview
The filter works when it's anything but a null but I'm trying to only the null ones to display. I could try changing all the null values to a default value string other than a null? Is there anywhere to get the filter to work with nulls?