Cookbook
Patterns, worked through
The reference tells you what every option and method is. This section is the other half: what people actually build, in the order they hit the problems — with examples that run rather than snippets that were never executed.
Shipped · every example runs How "runnable" is enforced here. Every headless example is a real module in
src/lib/cookbook/. Each page imports it twice — once as source, so the
snippet you copy is literally the file, and once as code, executed during the site build with its
real return values printed beneath it. A broken example fails the build. The browser-only
patterns run live on their page and are pinned by end-to-end tests.
By task
Field studies — the same patterns at full size
A study takes a page you already know and reinterprets the whole thing as a field: semantic HTML first, the platform runtime layered on top, diagnostics available, and a reduced-motion equivalent that loses nothing. They are worked patterns rather than a separate genre — where a cookbook page shows one technique in isolation, a study shows several of them holding a real page together.
- Reading Field
- A long-form article that measures attention and remembers it.
- Review Field
- A pull request as heat, tension and a reviewer constellation.
- Search Field
- Search results as a trust gradient with contradiction polarity.
- System Weather
- A metrics dashboard read as weather — heat, pressure, anomalies.
- Evidence Field
- Claims, sources and contradiction as a deterministic field.
- Visual Binding
- An expressive SVG bound to the semantic source it illustrates.
Where the rest of it lives
- The complete surface — every attribute, force, channel, option and method, each with a generated JS · Swift · Kotlin support row: the declarative and imperative references.
- The on-ramp — install, your first field, and the mental model.
- Real data at production scale — the twelve invisible-field examples.
- The catalog — 64 Patterns, applied live, in the pattern gallery.