1.0.0 • Published 8 years ago

sb-promise v1.0.0

Weekly downloads
4
License
MIT
Repository
github
Last release
8 years ago

Promise

A lightweight Promise Polyfill for Node and Browsers.

Installation

npm install sb-promise

Example

In case you don't know what Promises are, then this example should give you a basic intro.

function MyFunction(Num){
  return new Promise(function(Resolve, Reject){
    // Do something asyncly
    Resolve(Num * 100);
  });
}
MyFunction(5).then(function(Result){
  console.log(Result); // Outputs 500
});

License

This project is licensed under the terms of MIT License