I want to set default route to home page and I am using react router v5 but its not working,I am trying in this way, Index.js Here other routes ar ...
I want to set default route to home page and I am using react router v5 but its not working,I am trying in this way, Index.js Here other routes ar ...
My root App component looks like this: The problem with isAuthenticated is that when the app is first loaded before the user logs in its value is ...
i am getting this error i have read may another answers from this website. like someone said put browser router in index.js.i tried it but its not ...
Hey guys ı make movie app with movie database api. When route detail page ı am check the react router props match.params and fetching data with axios ...
I'm designing a website with a form component that redirects to a "failure" or "success" component based on whether the form submits without an error ...
I'm making a web app that has a main header that is valid for all its pages and a second header that should be different for the Start page and only t ...
Scroll restoration scrolls 8/10ths of the way up the page but not all the way. Not sure if my ScrollToTop component is flawed or if I'm using the rout ...
I have this big issue. I have developed a Gatsby website for the car parts market. The users can select car model and part type and receive a page wit ...
I currently have a situation where I have my main parent routes/switch within my App.js file but within a route within the App.js file, I have another ...
Please see sandbox. I'm having this code: Expecting /items to be default route. Items is loading links for available items: Once an item link i ...
I need multiple nested routes in react-router-dom in home Page --- Home --- Page 1 --- Page 2 --- About I have home page that contains two subs the ...
I have a code pattern that I know is not going to work but I am not able to reason it out. For code above, when you click the button, the function ...
Hope you are doing good. I have one question regarding react routing. I have 5 components defined in app.js file after one by one and created route fo ...
I am new to React js. I am implementing the drawer (material-ui), so when user clicks on left menu (LeftMenu.jsx); the respective component should get ...
I can try this code line; But it’s don’t display an error component on the page. I found one thing, Which one is at the top of the switch. it’s sho ...
this Component is mapping an array and I am passing index of array via onClick in another function and after console i got Object. And I really dont ...
Is there a way to use useNavigate() hook outside functional component in react-router v6? I'm trying to use navigate(url) inside a saga function. I kn ...
I'm currently trying to implement a website using Material-UI's drawer component. It works, when I click on the Drawer Items, it routes me to the corr ...
I want to allow routes only if the user has the appropriate role to visit them. I do the check both on the frontend and the backend, however when usin ...
I have to pass a function to another component using Link This is how I call a function this.props.location.state.testFavorite(); This is giving ...