Alternatives for managing asynchronous calls

We've now seen the general pattern for performing multiple asynchronous operations at once. While it wasn't too difficult to keeping track of the pending requests by hand, it can become tiresome if you have to do this often. It can also become more complex if you do not have as simple a starting point as the length of an array; for example, if you only perform a request when certain conditions are met, or if you perform more than one request per item.

There are a number of solutions available to help you manage asynchronous control flow. We'll look at a few of these and try applying them to our application. These are completely optional! There's nothing wrong with the code we just wrote, and in subsequent ...

Get CoffeeScript Application Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.