So i’ve been doing a SPA project with react and i’m now implementing protected routes on the react-router-dom routes. However some of my components need to receive functions or states as parameters and i don’t know how to do it. I was following the tutorial but it doesn’t explain how to do it.
This is how my component was before i try to do the protected route :
Can anyone help me create the protected route passing out parameters? I have some more routes to do and i cannot keep going on if i’m not able to do it.