This project is a frontend-only architecture backed by Supabase. It uses React (Vite), Chakra UI, TanStack Router, and TanStack Query.
-
Clone and Clean: Clone the repository and (optionally) wipe the git history if starting a new project.
-
Supabase Project:
- Create a new project at supabase.com.
- Enable Email Auth in the Authentication settings.
- Run
supabase initin the root (optional, if you want to use Supabase CLI for migrations).
-
Environment Variables: Copy
frontend/.env.exampletofrontend/.envand fill in your Supabase URL and Anon Key:cp frontend/.env.example frontend/.env
VITE_SUPABASE_URL=your-project-url VITE_SUPABASE_ANON_KEY=your-anon-key
-
Install Dependencies:
cd frontend npm install -
Run Development Server:
npm run dev
The app will be available at
http://localhost:5173.
- Frontend: Vite + React + TypeScript
- UI Components: Chakra UI v3
- Routing: TanStack Router
- Data Fetching: TanStack Query
- Authentication: Supabase Auth via
@supabase/supabase-js - Linting & Formatting: Biome
The app uses a custom useAuth hook and AuthProvider (in frontend/src/hooks/useAuth.ts) to manage session state.
- On mount, it checks for an existing session.
- It listens for auth state changes (sign in, sign out, user updates).
- Protected routes are guarded in
frontend/src/routes/_layout.tsx.
npm run dev: Start development servernpm run build: Build for productionnpm run lint: Run Biome linting and formatting