- Preparing search index...
- The search index is not available
atomic-fns
- filter<T>(arr: T[], fn?: Iteratee<T, any, any>): T[]
-
Parameters
-
arr: T[]
-
Optional
fn: Iteratee<T, any, any>
Returns T[]
- filter<T>(arr: T[], fn?: Object): T[]
-
Parameters
-
arr: T[]
-
Optional
fn: Object
Returns T[]
- filter<T>(arr: Object, fn?: Iteratee<T, any, any>): T[]
-
Parameters
-
arr: Object
-
Optional
fn: Iteratee<T, any, any>
Returns T[]
- filter<T>(arr: Object, fn?: Object): T[]
-
Parameters
-
arr: Object
-
Optional
fn: Object
Returns T[]
Iterates over elements of collection, returning an array of all elements where predicate returns truthy value.
The predicate is invoked with three arguments:
(value, index|key, arr)
.Example
Returns
The new filtered array