Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Bonus Step 6 - Create a UserFilter Context and Custom Hook #10
Here is where using Context really gets fun. We have a Selected User that needs to be passed through props to various components. While in this app, passing a prop through a couple of levels is really not a big deal, when you get to bigger apps, it can become unwieldy to pass props down through several levels. Instead, we can use the Context API to provide the data and use a custom hook to provide access to it.
We also put