Open kgilles opened 3 months ago
Did you envision this being resolved by adding middleware or do you want to add the checks directly into the protected hoc routes (forget the exact name of the component)?
Did you envision this being resolved by adding middleware or do you want to add the checks directly into the protected hoc routes (forget the exact name of the component)?
I believe we can add the referred path as a query parameter to the login page URL via the restricted page component.
If a logged out user tries to access a restricted page, such as the post-creation page, they will instead be directed to the login page. When this happens we want to keep track of the page the user attempted to access, and direct them there automatically after they successfully log in.
For example
/p
to create a post/login
/p