Writing Swirls
Writing Swirls
The mechanics of the language itself - syntax, file discovery, embedded code, and the mistakes the parser will catch you on.
These pages cover the act of writing .swirls files, across every primitive. Start with the primitives map if you want to know what to build; come here when you are writing it.
- How it works: what happens between writing a file and a running system.
- Syntax: comments, identifiers, values, schemas, and
@ts/@json/@sqlblocks. The complete top-level block list lives here. - Multi-file workflows: splitting declarations across files. Swirls systems span as many files as you need.
- Context: the
contextobject inside@tsblocks (nodes,reviews,secrets,meta,iteration). - Common mistakes: the incorrect patterns people (and agents) write most often, with corrections.