Is it possible to filter an array of objects, such that the value of property can be either of a few values (OR condition) without writing a custom filter>
In HTML:
In Angular: $scope.colorFilter = function (item) { if (item.color === 'red' || item.color === 'blue') { return item; } }; 0 讨论(0) 查看其它7个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复
In Angular:
$scope.colorFilter = function (item) { if (item.color === 'red' || item.color === 'blue') { return item; } };