Summary
In this chapter, we learned how JavaScript executes asynchronous code. We learned about event loops, and basically how JavaScript manages all asynchronous and multiple tasks without using any additional threads. We learned about different patterns for writing asynchronous code.
We saw how promises make it easier to read and write asynchronous code, and how async/await blows away promises in practice. In the next chapter, we'll take a look at how to organize your JavaScript code with a modular programming approach.