Skip to content

Execute javascript async callback in the right orders

Notifications You must be signed in to change notification settings

tranvansang/make-queue

Repository files navigation

Execution queue Build Status

NPM

Execute async callbacks in the correct orders.

API reference

There is only one function from the default import

import makeQueue from 'make-queue'
// or
const makeQueue = require('make-queue')
  • const queue = makeQueue(skipError): create a new queue queue. Default: skipError = true.
  • queue(cb): appends the cb callback to the queue and returns a promise which resolves the cb's results.

If skipError is false, once a callback in a chain throws an error, all following calls fail immediately and throw this error.

About

Execute javascript async callback in the right orders

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published