apr-reduce

Reduces coll into a single value using an async iteratee to return each successive step.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
apr-reduce
74673.0.36 years ago7 years agoMinified + gzip package size for apr-reduce in KB

Readme

reduce

Reduces coll into a single value using an async iteratee to return each successive step.

Parameters

Examples
import reduce from 'apr-reduce';

const sum = await reduce([1, 2, 3], async (sum, item) =>
  new Promise((resolve) => resolve(sum + item))
);

Returns Promise