How To
Documentation
    Learn More

      deepFilter

      Description

      Returns a subset of the given array, containing all the elements matching the given object filter. A filter is specified by a selector identifying a property of the objects in the array, and a value to match that property against. Matches are left-partial meaning that a match against "ca" will match both "car" and "cat".

      Usage

      In HTML Template Binding

      {{ deepFilter_expression | deepFilter:path:target }}

      In JavaScript

      $filter('deepFilter')(array, path, target)

      Parameters

      ParamTypeDetails
      arrayarray

      Array of objects to filter on.

      pathstring

      Path of the property to search for the target value

      targetstring

      The value you are looking to match against.

      Example

      Source

      
      
      
      
      
      

      Demo