Skip to content

exercises for a training session introducing the use of generators for async control flow

Notifications You must be signed in to change notification settings

jon-hall/generators-and-async

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 

Repository files navigation

generators-and-async

An introduction to how generators can be leveraged to flatten asynchronous code into a more manageable structure.

It comprises two basic exercises, the first of which illustrates how Promise-based code can be de-cluttered using generators to 'await' on promises. In the other example, we build our own miniature version of the library used in the first project (co) to understand how it actually works under the hood.

Prerequisites

In order to run the projects in this repo you'll need to have a version of node (>=4.0.0) installed (you can check your version by entering node -v in a command prompt). You can get the installer from here if you don't have node yet, or want to update.

You'll also need git (or a git client) to clone this repo.

Projects

Each folder contains a mini-project with it's own README which explains some of the concepts being illustrated, and how to complete each exercise, if you want to try it for yourself.

Completed versions of each of the projects will be found on the completed branch if you just want to skip to a finished version and look at, or play with, the code.

Project walkthroughs:

Further reading

About

exercises for a training session introducing the use of generators for async control flow

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published