p-promise

A simple Promises/A+ library.

npm install p-promise
12 downloads in the last day
367 downloads in the last week
1 186 downloads in the last month

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.onerror
  • P.nextTick(callback)
  • deferred.promise
  • deferred.resolve(value)
  • deferred.reject(reason)
  • promise.then(onFulfilled, onRejected)
  • promise.done(onFulfilled, onRejected)
  • promise.spread(onFulfilled, onRejected)
  • promise.timeout(ms, opt_timeoutMsg)
  • promise.delay(ms)
  • promise.inspect()
npm loves you