Closed nathanielfernandes closed 6 months ago
dashboard subpages are just not visible on the deployed build??
Currently in hooks.server.ts
, we redirect the user if they try to visit protected url without logging in.
However, the redirect handle runs only at the server-side, if you navigate through the app after it's loaded, everything is now handled client side. The redirect handle function is only called on fetch requests, initial loads and hard refresh.
I added code to layout component to watch for url changes on the client side, and perform redirects when necessary.
when visiting nested protected routes under dashboard, you can "visit" the page without being signed in.
needs to redirect back to index with a login request.