Lesson 31. Advanced promises
After reading lesson 31, you will be able to
- Create your own promises
- Wrap callback-based methods with promises
- Use and understand how to properly write nested promises
- Understand how error handling propagates in promise chains
In the previous lesson you learned the basics of promises. We’ll now take a more advanced look at creating new promises and converting asynchronous code to use promises. We’ll look at advanced error handling, using promises for multiple asynchronous calls, and other advanced usages.
Sometimes you need to make multiple asynchronous calls to get the data you need. A piece of data relies on another piece of data, which relies on yet another piece of data. Yet all ...
Get Get Programming with JavaScript Next 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.