I have a webapp and have a problem with private / secured routes within my App.js.
I read and executed this tutorial for creating an authentication within my react app: https://auth0.com/blog/role-based-access-control-rbac-and-react-apps/#Authentication-in-React-Apps-with-Auth0
Until the section “After creating these components, you can update the
Home component to enable users to log in:” it was simple to implement the code. In my App.js I created an
<PrivateRoute> component where only authenticated users can access the app. But everytime I want to login I will be redirected to the login page instead of the
Here an extract from my App.js: https://hastebin.com/amineyumuj.xml
What I’m doing wrong?
Or do you need more information?
Thanks in advance