Overview
The home page at / currently renders only <h1>HomePage</h1>. There is no redirect logic. If a user navigates to the root URL, they see a blank page instead of being sent to the appropriate destination.
Context
- File:
frontend/app/page.tsx
- The Zustand auth store at
frontend/store/auth.store.ts exposes isAuthenticated and loadUser()
- The middleware at
frontend/middleware.ts already protects dashboard routes — the home page itself is unprotected
- Pattern: check auth state on the client, redirect with
useRouter from Next.js, or use a server-side redirect in page.tsx
Acceptance Criteria
Overview
The home page at
/currently renders only<h1>HomePage</h1>. There is no redirect logic. If a user navigates to the root URL, they see a blank page instead of being sent to the appropriate destination.Context
frontend/app/page.tsxfrontend/store/auth.store.tsexposesisAuthenticatedandloadUser()frontend/middleware.tsalready protects dashboard routes — the home page itself is unprotecteduseRouterfrom Next.js, or use a server-side redirect inpage.tsxAcceptance Criteria
loadUser()to verify the current session/dashboardusingrouter.replace('/dashboard')/login<h1>HomePage</h1>text