Learning to write asynchronous code takes time and effort. If you find yourself stuck at some point, and you feel you’re not making progress, first take a break. Then, find another resource that explains the topic you don’t understand, or revisit something you read previously—you’ll discover something you’ve missed on the first read.
I’m not sure who is this post for, but I can tell you how I felt before I started reading. I’ve used promises and async/await in my code before, but when things were complicated:
- I wasn’t 100% sure that I was using them correctly.
- I was observing some behavior that I couldn’t explain.
If that sounds familiar, you’ll find the resources recommended here valuable.
I broke it in 3 parts because each topic deserves a separate page, and because I plan to add more resources in the future. As a result, one page won’t be enough. I may also add new pages for other asynchronous topics like generators or even callbacks. For now, these topics are under the “Further reading” section.
Other things to read
- Reveal animations on scroll with react-spring
- Gatsby background image example
- Extremely fast loading with Gatsby and self-hosted fonts