tinywork
只做了一点微小的工作。
Installation
You can install it as dependency via npm
.
$ npm install tinywork --save// or$ cnpm install tinywork --save
Usage
tinywork can process mix Promise list or mix Object.
mix object
You can use co
and yield
like this:
; // => a: 1 b: 2 c: 'c'
And use async/await
like this:
await ; // => a: 1 b: 2 c: 'c'
mix array
You can use co
and yield
like this:
; // =>1 2 'c';
And use async/await
like this:
await ; // =>1 2 'c';
Others
Just return resolved Promise with value.
License
The MIT license