6
Routing with React Router
In this chapter, we will build a simple app implementing the following pages:
- A home page that welcomes the user
- A products list page that lists all the products
- A product page that provides details about a particular product
- An admin page for privileged users
This will all be managed using a library called React Router.
Through this, we will learn how to implement static links from the products list to the product page and implement route parameters on the product page for the product ID. We will also learn about form navigation and query parameters when it comes to the search feature of our app.
Finally, the chapter will end with how to lazily load code for a page to improve performance.
So, in this chapter, we ...
Get Learn React with TypeScript - Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.