Skip to content

Commit

Permalink
docs: updated a bit of readme file
Browse files Browse the repository at this point in the history
  • Loading branch information
fahimfaisaal committed Jan 30, 2024
1 parent d47dade commit d0bc5fe
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,16 @@ const settled = settleMap(
},
2 // the concurrency you want to set
);

// or
import { createSettleMap } from "settle-map";

// use this map function all over the place with same options
const map = createSettleMap({ concurrency: 2 });

const settled = map(items, asyncMapFunction);
// even you could override the default options. like below the concurrency will changed from 2 to 5
const result = await map(item, asyncMapFunction, 5);
```

### Get live response by listening events
Expand Down

0 comments on commit d0bc5fe

Please sign in to comment.