Module 2 Recap
Here we're going to recap what we've learned in Module 2
Get the project source code below, and follow along with the lesson material.
Download Project Source CodeTo set up the project on your local machine, please follow the directions provided in the README.md
file. If you run into any issues with running the project source code, then feel free to reach out to the author in the course's Discord channel.
This lesson preview is part of the React Data Fetching: Beyond the Basics course and can be unlocked immediately with a \newline Pro subscription or a single-time purchase. Already have access to this course? Log in here.
Get unlimited access to React Data Fetching: Beyond the Basics, plus 70+ \newline books, guides and courses with the \newline Pro subscription.

[00:00 - 00:07] A big congratulations for getting to the end of this module. There's a lot we've done, so let's have a quick recap.
[00:08 - 00:21] We've learned how to fetch data before a React component loads, which is a huge performance win for your users. We've also learned how to put data in a cache and only fetch data if it doesn't exist in the cache.
[00:22 - 00:37] Nice. We've also learned how to fetch data on an event, so a click, a hover, a scroll , and in the case of our project, we triggered a "FET" on hover, but the same technique can be used for any event.
[00:38 - 00:52] And finally, we've learned how to add loading and error states to our data fetching. So we've added statuses to our cache data and formatted the statuses to return the correct object.
[00:53 - 01:10] Wow, that is a lot of information to take in. If we take a look at this screenshot from the React website, we can see that the data fetching code we've written takes care of the data fetching and caching problem from this documentation.
[01:11 - 01:20] But we still have a few more things to implement. In the next module, we'll be looking at how to handle race conditions and network waterfalls.
[01:21 - 01:33] But before we do that, I highly recommend that you take a break and go through the code and the notes again to make sure that you understand what you've just written. Cool.
[01:34 - 01:59] Of course, there's no pressure, but when you're ready, let's move on to the next module. [ Pause ]