co-timer

Generator based timeout

This is a small generated based timer library. It allows you to yield to wait for a timeout. If you want to learn about generators, see the article Working with Koa and Generators.

$ npm install co-timer
co(function* () {
  yield timer(3000);
})();
 

MIT