Skip to content
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 

README.md

Async Generators

Proof that async generators dont need async/await

example

var async   = require('./engine')
var Promise = require('bluebird');

var tenNumbers = async(function* tenNumbers() {
    for (var k = 0; k < 10; ++k) {
        yield async.await(Promise.delay(100));
        console.log(k);
        yield async.yield(k);
    }
})

async.iterate(tenNumbers(), val => console.log("Iterating", val));

license

public domain / MIT

About

Proof that we don't need async/await to get async generators

Resources

Releases

No releases published

Packages

No packages published