On this page
Improve this Doc View Source filter
- filter in module ng
Selects a subset of items from array
and returns it as a new array.
Usage
In HTML Template Binding
{{ filter_expression | filter : expression : comparator}}
In JavaScript
$filter('filter')(array, expression, comparator)
Arguments
Param | Type | Details |
---|---|---|
array | Array |
The source array. |
expression | string Object function() |
The predicate to be used for selecting items from Can be one of:
|
comparator | function(actual, expected) true undefined |
Comparator which is used in determining if the expected value (from the filter expression) and actual value (from the object in the array) should be considered a match. Can be one of:
|
© 2010–2017 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://code.angularjs.org/1.3.20/docs/api/ng/filter/filter