Open robharding opened 1 year ago
forgot- both files will now need "use client"; on the first line because we are using the onClick hook.
This broke navigation when opening a modal from the sign up/sign in page, as closing the modal would take you to where you were before that page(not the page itself).
Awesome thanks for the PR, gonna look into it as soon as I find the time
Instead of onClick, the SignIn and SignUp can use the replace property to replace the current route in the case it's already on a modal.
Thanks, works well!
Hi Josh, thanks for the great tutorial. I was having issues getting the modals to behave as expected. To reproduce bring up the sign in modal, and then click the sign up button. If you try closing the sign out modal, it brings you back to the sign in modal instead of the expected page. My fix is to replace the page in the router instead of navigating.