This repository provides code samples for the React Router Dom v6.8 tutorial, which can be found on the official React Router website.
The code is organized by branch; the main branch being the final code from the tutorial with minor modifications.
The branches of this repository include:
-
Quick setup - a simple setup to get started.
-
Adding a router - demonstrates the process of adding a router to a React application
-
Adding routes and nested routes - shows how to add and manage routes in your React application
-
CRUD operations - covers the creation, reading, updating, and deletion of data in your React application
-
Contextual errors and miscellaneous topics - deals with error handling and miscellaneous features of the React Router Dom library
-
Search parameters, history stack, JSX routes, and more. - covers advanced topics like search parameters, history stack, and JSX routes.
To run the code, you need to clone the repository and install its dependencies
- Clone the repository using the following command:
git clone https://github.com/marqetintl/react-router-dom-v6.8-tutorial react-tutorial && cd react-tutorial
- Next, install the dependencies:
npm install
- Finally, run the development server:
npm run dev