A SvelteKit 5 application for managing D&D Adventurers League campaigns, with local development powered by Supabase and modern Svelte tooling.
- Node.js v22 or later
- Bun v1.2.19+ (recommended), or pnpm / npm
- Supabase CLI (for local database)
- Docker (optional, for running Supabase locally)
-
Clone the repository:
git clone cd ddal-svelte
2. **Copy and configure your environment variables:**
```bash
cp .env.example .env
# Edit .env to match your local setup (database credentials, API keys, etc.)
The
.env
file is required for local development. See.env.example
for required variables.
-
Install dependencies:
Using Bun (recommended):
bun install
Or with pnpm:
```bash
corepack pnpm install
Or with npm:
npm install
By default, the dev script will start Supabase and the SvelteKit dev server.
- With Supabase CLI (recommended):
supabase start
This will spin up the local database and Supabase services using Docker.
- **With Docker Compose (alternative):**
If you want to run Supabase manually, follow the [Supabase Docker quickstart](https://supabase.com/docs/guides/self-hosting/docker) and ensure your `.env` and `supabase/config.toml` are configured.
## Development
Start the local dev server (and Supabase):
```bash
corepack pnpm dev
# or
bun run dev
# or
npm run dev
- The app will be available at http://localhost:5173 (or as configured by Vite).
- Supabase Studio will be available at http://localhost:54323 by default.
To create a production build:
corepack pnpm build
# or
bun run build
# or
npm run build
Preview the production build:
corepack pnpm preview
# or
bun run preview
# or
npm run preview
corepack pnpm lint
corepack pnpm format
- The project uses Drizzle ORM for database access.
- See
supabase/
for database schema and migrations. - For more details, check the scripts in
package.json
.