title: JavaScript asynchronous programming: promises vs generators
body: <p>Promises and generators allow you to write asynchronous code. I do not understand why both of these mechanisms are introduced in ECMA script 6. When is it best to use the promises, and when the generators?</p>