Protected routes let us choose which routes users can visit based on whether they are logged in. For example, you might have public routes that you want anyone accessing, like a landing page, a pricing page, and the login page. This is a tutorial about React Router protected routes and not about authentication, we'll use a fake Hook.
Table of contents
Before you leaveSort: