mirror of
https://github.com/TanStack/router.git
synced 2026-11-16 19:38:07 +00:00
|
History
|
||
|---|---|---|
| .. | ||
| .vscode | ||
| src | ||
| .env | ||
| .gitignore | ||
| .prettierignore | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
| vite.config.ts | ||
TanStack Start - Supabase Example
A TanStack Start example demonstrating integration with Supabase for authentication and database.
Start a new project based on this example
To start a new project based on this example, run:
npx gitpick TanStack/router/tree/main/examples/react/start-supabase-basic start-supabase-basic
Setup
This example requires Supabase configuration. The .env file contains the necessary environment variables:
VITE_SUPABASE_URL=your-project-url
VITE_SUPABASE_ANON_KEY=your-anon-key
You'll need to:
- Create a Supabase project at supabase.com
- Get your project URL and anon key from the project settings
- Update the
.envfile with your credentials
Getting Started
From your terminal:
pnpm install
pnpm dev
This starts your app in development mode, rebuilding assets on file changes.
Build
To build the app for production:
pnpm build
Supabase Integration
This example demonstrates:
- Authentication with Supabase Auth
- Database queries with Supabase client
- Real-time subscriptions
- Server-side data fetching