Skip to content
0

katanakit-js / useReduce

Function: useReduce() ​

ts
function useReduce<T, U>(
   array, 
   reducer, 
   initial
): U;

Defined in: src/core/services/array.service.ts:505

Folds into a single value. See ArrayService.useReduce.

Type Parameters ​

Type Parameter
T
U

Parameters ​

ParameterType
arrayNullableArray<T>
reducer(accumulator, item, index) => U
initialU

Returns ​

U

Released under the MIT License.