p-promise

0.5.0 β€’ Public β€’ Published

Build Status

Promises/A+ logo

P

A simple Promises/A+ library.

API

P implements a subset of the Q API.

  • P(val)
  • P.reject(reason)
  • P.defer()
  • P.all(promises)
  • P.allSettled(promises)
  • P.spread(promises, onFulfilled, onRejected) πŸ†•
  • P.promised(aFunction)
  • P.denodeify(aFunction) πŸ†•
  • P.onerror
  • P.longStackSupport πŸ†•
  • P.nextTick(callback)
  • deferred.promise
  • deferred.resolve(value)
  • deferred.reject(reason)
  • promise.then(onFulfilled, onRejected)
  • promise.done(onFulfilled, onRejected)
  • promise.fin(callback) πŸ†•
  • promise.spread(onFulfilled, onRejected)
  • promise.all()
  • promise.allSettled()
  • promise.timeout(ms, opt_timeoutMsg)
  • promise.delay(ms)
  • promise.inspect()
  • promise.nodeify(nodeback) πŸ†•

Package Sidebar

Install

npm i p-promise

Weekly Downloads

131

Version

0.5.0

License

MIT

Last publish

Collaborators

  • rkatic