Chapter 5: Reusable React Components and React Hooks
We have done a lot to reach this point in the book, including saving, requesting, inserting, and updating data through the use of Apollo Client, in connection with our GraphQL application programming interface (API). Much of the code that we have written will also have to be reviewed many times. This is especially important because we are building an application so quickly. Everything is working for now, but we have not done a great job here; there are some best practices and tactics that need to be observed in order to write good React applications.
This chapter will cover everything you need to know to write efficient and reusable React components. It will cover the following topics:
- Introducing React patterns
- Structuring our React application
- Extending Graphbook
- Documenting React applications