# p-promise

> A simple Promises/A+ library.

Latest version **0.5.0** (published 2014-12-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install p-promise
pnpm add p-promise
yarn add p-promise
bun add p-promise
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.5.0 |
| Published | 2014-12-08 |
| First published | 2013-02-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 34 |
| Author | Robert Katić |
| Maintainers | rkatic |
| Keywords | promise, promises, promises-aplus, browser, node |

## Links

- npm: https://www.npmjs.com/package/p-promise
- Repository: https://github.com/rkatic/p
- Issues: https://github.com/rkatic/p/issues
- npm.io page: https://npm.io/package/p-promise

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 0.5.0 (latest) — 2014-12-08
- 0.4.9 — 2014-11-10
- 0.4.8 — 2014-08-21
- 0.4.7 — 2014-08-11
- 0.4.6 — 2014-08-05
- 0.4.5 — 2014-07-31
- 0.4.4 — 2014-07-31
- 0.4.1 — 2014-07-29
- 0.4.0 — 2014-07-28
- 0.3.8 — 2014-07-19
- 0.3.7 — 2014-07-17
- 0.3.6 — 2014-07-16
- 0.3.5 — 2014-07-16
- 0.3.4 — 2014-07-11
- 0.3.2 — 2014-06-12
- … 26 more at https://npm.io/package/p-promise/versions

## README

[![Build Status](https://travis-ci.org/rkatic/p.png?branch=master)](https://travis-ci.org/rkatic/p)

<a href="http://promises-aplus.github.com/promises-spec">
    <img src="http://promises-aplus.github.com/promises-spec/assets/logo-small.png"
         alt="Promises/A+ logo" title="Promises/A+ 1.0 compliant" />
</a>

#P

A simple Promises/A+ library.

- Implements a subset of the the [Q](https://github.com/kriskowal/q) API.
- Passing the [Promises/A+ Compliance Test Suite](https://github.com/promises-aplus/promises-tests).
- Cross-Browser, Node.js and RequireJS ready.
- Supports domains.
- Small.
- Simple.
- [Fast](http://jsperf.com/davy-jones-benchmark/32).

##API

P implements a subset of the [Q](https://github.com/kriskowal/q) API.

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

---
_Source: https://npm.io/package/p-promise · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
