templates.SimpleTodo/README.md

54 lines
2.9 KiB
Markdown

# Simple Todo List — W4C project template
A W4C **project template** and the platform's deliberately **minimal demo**: creating a project
from it generates a copy of this repository in your namespace and starts the **Startup Creator**
agent, which builds the smallest useful website from this brief — a single static todo-list page
with no backend, no build step and no dependencies.
This repository is a **brief, not a finished app**: it ships the specification and the project
metadata; the Startup Creator drives the build and hands each layer to the right specialist. Read
[`SPEC.md`](SPEC.md) for the full contract — the screen, the data model, the flows, the
non-functional requirements and the acceptance criteria the work is checked against.
## What ships in this repository
| Path | Purpose |
|------|---------|
| `README.md` | This file: how the template is wired and how to work in the project. |
| `SPEC.md` | The product specification and acceptance criteria — the contract to work against. |
| `.w4c/template.json` | Template manifest: dialog fields, dev-server startup conditions, starter prompt, element list (templates only). |
| `.w4c/project.json` | Project metadata committed with the repository. |
| `.w4c/README.md` | The `.w4c/` folder contract. |
| `.w4c/preview.svg` | Catalog thumbnail for the template picker. |
| `.w4c/boards/roadmap.json` | The reduced layer → task seed for a minimal demo. |
This template intentionally ships **no `diagrams/` or `workflows/` folders** and no `diagram` /
`workflow` element: the Startup Creator drops the layers a single static page does not need
(architecture diagram, database, backend, admin, control panel, workflows) and files only
🧭 plan & scope, 💻 frontend, 🚀 run & preview and ✅ quality.
## Stack
The website is **plain HTML + CSS + JavaScript** — no framework, no package manager, no bundler.
The template's `devServer` section publishes the folder as a static site (a static file server on
the project port), so there is no install step to run. Keep it dependency-free to stay the easiest
possible demo.
## Build order
Work top-down, one stage at a time, and verify each stage before the next (details in `SPEC.md`
§8):
1. **Skeleton** — `index.html` with the header, composer, list and footer; serve it.
2. **Model + storage** — the `Todo` shape and `localStorage` load/save with a corrupt-value fallback.
3. **Interactions** — add, toggle, delete, clear completed, filters, counts, keyboard support.
4. **Polish + quality** — responsive, accessible, injection-safe, README quickstart, acceptance pass.
## Working rules
- Keep it minimal: no backend, no accounts, no database, no analytics, no service worker.
- Render user input as **text**, never as HTML.
- One concern per commit, conventional messages (`feat:`, `fix:`, `chore:`, `docs:`, `test:`).
- Never commit secrets.
- Keep `docs/PLAN.md`, the board and `.w4c/project.json` in sync as the project evolves.