Skip to content

anzerr/promise.util

Repository files navigation

Intro

GitHub Actions status | linter GitHub Actions status | publish GitHub Actions status | test

simple es6 promise util.

Install

npm install --save git+https://git@github.com/anzerr/promise.util.git
npm install --save @anzerr/promise.util

Example

Look at tests for more usage examples

const promise = require('promise.util');
const data = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];

promise.measure(() => {
	return promise.each(data, () => promise.delay(1000), 5);
}).then((res) => {
	console.log(Math.round(res / 1e9)) // 2
});

About

small promise util

Topics

Resources

License

Stars

Watchers

Forks

Packages