- rollups<TObject, TReduce, TKeys>(iterable, reduce, ...keys): NestedArray<TObject, TReduce, TKeys>
Type Parameters
TObject
TReduce
TKeys extends unknown[]
Parameters
iterable: Iterable<TObject>
reduce: ((values) => TReduce)
- (values): TReduce
Returns TReduce
Rest
...keys: {
[Index in string | number | symbol]: ((value, index, values) => TKeys[Index])
}
Returns NestedArray<TObject, TReduce, TKeys>
Equivalent to rollup, but returns nested arrays instead of nested maps.