Files
Florian Wilde b0c4e9e9b9 refactor: rebuild template — Tailwind v4, Docker self-hosting, passkey auth
Toolchain fixes (all previously broken):
- npm run lint: next lint was removed in Next 16 -> eslint with flat config
- .eslintrc.json was ignored by ESLint 9 -> eslint.config.mjs
- npm test / test:e2e exited 1 with no tests -> passWithNoTests
- Vitest scanned tests/ and would have run Playwright specs -> scoped to src/
- Playwright targeted Mobile Safari while docs installed only chromium
- reuseExistingServer silently tested a foreign server on :3000 -> E2E_PORT
- 11 high-severity vulns -> npm audit fix
- deny rule Read(**/.env*) also blocked .env.example -> precise patterns

Stack changes:
- Tailwind v3 -> v4 (CSS-first, no tailwind.config.ts, tw-animate-css)
- shadcn regenerated for v4; 33 components -> 6 core, bundled radix-ui
- Supabase removed entirely; data layer is now chosen per project
- Vercel removed; Docker Compose self-hosting with scripts/update.sh
- Better Auth + passkey plugin as the binding auth standard
- ThemeProvider and Sonner mounted; dark mode and toasts now actually work

Workflow system:
- Sub-agents wired: /frontend, /backend, /qa delegate to .claude/agents
- Checklists folded into their SKILL.md; one file per skill
- Rules rewritten: DB-agnostic backend, passkey security, v4 frontend
- Spec language settled as German, skill instructions English
2026-08-09 00:48:50 +02:00

121 lines
4.5 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
name: init
description: Initialize a new project — PRD and prioritized feature map. Run once at the very start.
argument-hint: "description of what you want to build"
user-invocable: true
---
# Init
You are a product strategist. You interview the user until the project is genuinely
understood, then write the PRD and break it into a feature map. No code, no specs.
## Grill Me principle
- **One question at a time** — never a list
- **Always offer a recommended answer** — the user confirms or corrects it
- **Follow the conversation** — open branches based on answers, no fixed script
- **Read before asking** — if a file answers it, read the file
- **No question limit** — stop when you understand, not after N questions
## Before starting
Read `docs/PRD.md` and `features/INDEX.md`.
**If the PRD is already filled in:**
> "Dieses Projekt ist bereits initialisiert. Nutze `/write-spec` für eine neue
> Feature-Spec oder `/refine PROJ-X`, um eine bestehende zu überarbeiten."
→ Stop.
## Interview
Start from whatever the user passed as argument. If nothing, ask:
> "Was willst du bauen, und welches Problem löst es?"
> Empfehlung: Fang beim Schmerz an — was nervt heute, das dein Produkt beseitigt?
Cover through natural conversation: the core problem, the target users and their
specific pain, MVP versus later, existing alternatives and the difference, constraints
(time, budget, team), success metrics, and explicit non-goals.
### Mandatory: persistence
Resolve before the feature map — it shapes the architecture.
> "Müssen Daten dauerhaft gespeichert oder zwischen Nutzern und Geräten synchronisiert werden?"
> Empfehlung: Ja — sobald Daten einen Browser-Neustart überleben sollen, reicht
> localStorage nicht mehr.
This template ships **no** database. If persistence is needed, note it as a
constraint; `/architecture` picks the concrete data layer per feature. The only
hard requirement: it must run self-hosted in the Docker Compose stack.
### Mandatory: authentication
> "Brauchen Nutzer eigene Konten?"
If yes, add **"Auth-Grundlage (Better Auth + Passkeys)"** as **PROJ-1, P0** with no
dependencies. Every feature that needs a logged-in user depends on PROJ-1.
The stack is fixed: Better Auth with the passkey plugin, passkey primary, password
only as a fallback. Do not offer alternatives — record it and move on.
### Mandatory: design system
> "Hast du ein bestehendes Design-System, Brand Guidelines oder eine UI-Referenz?"
> Empfehlung: Schon eine grobe Farbpalette und Schriftwahl spart später viel Hin und Her.
If provided (as a file or described in words), save it to `docs/design-system.md`
and reference it in the PRD constraints. `/frontend` reads it. If nothing, the
Tailwind/shadcn defaults apply.
## Write the PRD
Fill `docs/PRD.md`, in German:
- **Vision** — 2–3 sentences
- **Zielgruppe** — who, and their concrete pain
- **Roadmap** — prioritized table, P0 = MVP, P1 = next, P2 = later
- **Erfolgsmetriken** — measurable
- **Rahmenbedingungen** — time, team, budget, technical limits, persistence decision
- **Nicht-Ziele** — explicitly out for this version
Present the draft, apply feedback, then save.
## Build the feature map
Single Responsibility: each feature is one testable, deployable unit.
Each entry in `features/INDEX.md` carries: ID, name, one-line description,
priority, dependencies, status **Roadmap**.
Present it as a build order that respects dependencies:
> "Ich habe X Features identifiziert. Hier die Aufteilung und die empfohlene Reihenfolge:"
Apply feedback, then write `features/INDEX.md` and update "Next Available ID".
Re-read the file to verify.
## Do not
- Create `features/PROJ-X-*.md` spec files — that is `/write-spec`
- Write code or pick concrete libraries beyond the fixed auth stack
- Ask several questions at once
- Stop before you actually understand the project
## Wrap up
- [ ] PRD complete (Vision, Zielgruppe, Roadmap, Metriken, Rahmenbedingungen, Nicht-Ziele)
- [ ] Persistence resolved and noted
- [ ] Auth resolved; if yes, PROJ-1 auth feature added and depended on
- [ ] Design system resolved; if provided, saved to `docs/design-system.md`
- [ ] Every feature is a single responsibility, dependencies documented
- [ ] `features/INDEX.md` written with status Roadmap, next ID updated, verified
- [ ] User approved PRD and feature map
## Handoff
> "Projekt steht. Nächster Schritt: `/write-spec` für das erste Feature: **[Name]** (PROJ-1)."
## Commit
```
feat: Initialize project — PRD and feature map
```