1.0.0 • Published 8 years ago

yio-q v1.0.0

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

Q — library for promises Build Status

Promise/A+ is the specification what this implementation follow. It can be used in any allowed way under Promise/A+.

This implementation is quite small, and it is easy to merge into other code without introduction of redundant code. This is very helpful when developing a webapp.

Environments in which to use Q

  • Browser support
  • Nodejs
  • Browser extensions

Runing the Unit Tests

You need the necessary dependencies:

npm install

Run tests

npm test

Tutorial

Q(function(resolve, reject) {
    // Async or sync operation
    // success: resolve(val)
    // error: reject(reason)
}).then(function(val) {
    // onresolved
}, function(reason) {
    // onrejected
});

License

Copyright 2015–2016 Xiao-Bo Li MIT License

1.0.0

8 years ago