0.2.0 • Published 7 years ago

typescript-promise v0.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
7 years ago

typescript-promise

A simple, small promise library written in Typescript with some extra tricks up it's sleeve.

  • Based on Zousan
  • Under 800 bytes gzipped
  • Supports unlimited arguments passing through the promises.
  • Full typings
  • Mostly A+ Compliant

Usage

This lib exposes the TSPromise variable, use it just as you would Promise

import { TSPromise } from "typescript-promise";

new TSPromise((res, rej) => {
    res(1, 2, 3);
}).then((arg1, arg2, arg) => {
    console.log(arg1, arg2, arg3) // <= 1,2,3
});

If you need help on how to use Promises then consult the MDN Docs

0.2.5

7 years ago

0.2.4

7 years ago

0.2.3

7 years ago

0.2.2

7 years ago

0.2.1

7 years ago

0.2.0

7 years ago