- Preparing search index...
- The search index is not available
Utils
- reduceTruthy<T>(array: T[], check: ((entry: T, i: number) => boolean)): boolean
-
Parameters
-
array: T[]
-
check: ((entry: T, i: number) => boolean)
-
- (entry: T, i: number): boolean
-
Returns boolean
Returns boolean
Reduce the array into a single boolean value for if the check function returns true.
once the first
false
is encounteredcheck
is not run againReturns
true
ifcheck
only ever returnedtrue
, otherwisefalse