promiscuous

promiscuous is a tiny implementation of the Promises/A+ spec.
It is promise library in JavaScript, small (< 1kb minified / < 0.6kb gzipped) and fast.
Installation and usage
Node
First, install promiscuous with npm.
$ npm install promiscuous
Then, include promiscuous in your code file.
var Promise = ;
Browsers
Include promiscuous in your HTML file.
This version (and a minified one) can be built with:
$ build/build.js
API
Create a resolved promise
var promise = Promise;promise;/* one */
Create a rejected promise
var brokenPromise = Promise;brokenPromise;/* "Could not keep promise." */
You can also use the catch
method if there is no success callback:
brokenPromise;/* "Could not keep promise." */
Write a function that returns a promise
{ return { ; };};/* something */ ;/* nothing */
Convert an array of promises into a promise for an array
var promises = ;Promiseallpromises;/* [1, 2, 3] */