| title | Todo App |
|---|---|
| version | 0.1 |
| status | draft |
| created | 2026-05-15 |
| last_updated | 2026-05-15 |
| source | hand-written |
| owner | santosh |
A small web-based todo list application where a single user can manage tasks: add, view, mark complete, and delete. Built as a two-tier web app (separate frontend and backend processes) to exercise SAM's planning + contract-driven build pipeline on a realistic, demoable system.
- A user can manage their todos in a browser without errors.
- Frontend and backend run on separate ports and talk through a real HTTP API.
- App works when launched via
npm run devfrom a fresh checkout.
- Authentication / multi-user / accounts
- Persistent storage across server restarts
- Mobile-specific layouts
- Internationalization
Single user. No accounts. Primary journey: open browser → see existing todos → add new todo → complete or delete existing.
- Add todo: user types a title and submits; the new todo appears immediately at the top of the list.
- List todos: all todos visible with title and completion state, newest first.
- Mark complete: user toggles a todo's completion state; visual state updates.
- Delete todo: user removes a todo; it disappears from the list.
- Validation: title is required, non-empty, length ≤ 200 characters. Invalid input returns a clear inline error.
- API endpoints respond p95 < 50ms (in-memory store; trivial).
- No JS runtime errors in the browser console for any happy-path or validation-rejection flow.
- CORS configured for the Vite dev origin only — no wildcards.
- Bootable:
npm install && npm run devfrom a fresh clone starts both processes without manual intervention.
- Frontend: React 18 + Vite + TypeScript, served on
http://localhost:5174. - Backend: Fastify + TypeScript, served on
http://localhost:3001. - Layout: npm workspaces with
client/andserver/packages. - Storage: in-memory
Mapin the server process — no database in v1. - Concurrent dev: root
npm run devscript usesconcurrentlyto start both workspaces.
- User accounts, authentication, sessions
- Database / persistent storage
- Drag-to-reorder, tag editing, filtering, search
- Mobile-specific responsive behavior