1.1.3 • Published 5 years ago

bolocess v1.1.3

Weekly downloads
1
License
MIT
Repository
-
Last release
5 years ago

bolocess

task process handler for boloto

Install

npm i bolocess

API

const { concurrent, series } = require('bolocess')
// concurrency mode with limit 4
concurrent(array, function(item, callback) {
    console.log(item)

    // call callback when finish task
    callback()
}, 4, function() {
    console.log('finish')
})

// series mode with delay 500ms
// finish callback is optional
series(array, function(item, callback) {
    console.log(item)
    callback()
}, 500)