Quilt in 5 minutes

A guided walkthrough. Click through 7 steps. At each step, the cells come alive. By the end, you'll have built a working reactive system.

1Hello, cell
2Reactive
3Listener
4Sensor
5Router
6Time
7Mesh
Step 1 of 7

Hello, cell

A Quilt cell is a named, addressable value. The smallest possible sheet has one cell.

id: hello
title: "Hello, world"
version: 0.1.0
cells:
  - id: greeting
    kind: value
    value: "Hello, world!"
Three things to notice: the cell has a name (greeting), a kind (value), and a value ("Hello, world!"). The name is the cell's address — you reference it from anywhere.

The cell, live

greetingvalue"Hello, world!"
Step 2 of 7

Reactive

A formula cell is a function of other cells. When an input changes, the formula recomputes. The whole thing is reactive.

- id: price
  kind: value
  value: 100

- id: tax_rate
  kind: value
  value: 0.08

- id: total
  kind: formula
  expr: "price * (1 + tax_rate)"
The reactive flow: change price or tax_rate, and total automatically updates. You don't write the propagation — the engine handles it.

The cells, live

pricevalue100
tax_ratevalue0.08
totalformula108
Step 3 of 7

Listeners fire on change

A listener watches a cell. When the value changes, the listener fires. That's where the side effects live — notifications, logs, writes, anything.

- id: temperature
  kind: value
  value: 22

- id: alert
  kind: listener
  watch: temperature
  condition: "temperature > 30"
  action: 'console.log("⚠️ Hot!")'
The reactive + listener combo: when temperature goes above 30, the listener fires. The console log appears. You could send a notification, write to disk, or call an API — same pattern.

Set temperature to 35

temperaturevalue22
alertlistener
Step 4 of 7

Sensors read the world

A sensor cell reads from the physical world. A temperature sensor, a clock, a websocket. The cell holds the latest value.

- id: sensor.temp
  kind: sensor
  source: dht22
  default: 22

- id: sensor.humid
  kind: sensor
  source: dht22
  default: 50

- id: heat_index
  kind: formula
  expr: "sensor.temp + (sensor.humid - 50) * 0.05"
The sensor is a window: the value updates whenever a new reading arrives. In Quilt Live, this is simulated. On an ESP32, this is a real DHT22 sensor. The cell model is the same.

Live sensor readings

sensor.tempsensor22.0
sensor.humidsensor50.0
heat_indexformula22.0
Step 5 of 7

Routers dispatch by caller

A router cell returns different values for different callers. The same cell id, different outputs based on context.

- id: data.public
  kind: router
  routes:
    - when: "caller.role === 'admin'"
      expr: "all_data"
    - when: "caller.role === 'user'"
      expr: "filtered_data"
    - when: "caller.role === 'guest'"
      expr: "public_data"
Context-aware dispatch: when the admin calls data.public, they see everything. When a guest calls, they see only the public bits. The cell is the policy.

Call as different roles

data.publicrouter
Step 6 of 7

Time travel

With quilt-time, every cell has a history. You can rewind, replay, fork, merge.

const q = new QuiltTime();
q.set('counter', 0);
q.set('counter', 1);
q.set('counter', 2);

q.at('counter', 1);   // → 0
q.fork('experiment');  // snapshot
q.rewind('main');     // back to 2
Every cell has a past: this is what makes Quilt a database + a runtime. The cell is a value over time. The engine is small (~3 KB) but the API is real.

The timeline

countervalue0
t=1history0
t=2history1
t=3history2
Step 7 of 7

The mesh

With quilt-mesh, cells sync peer-to-peer. No server, no internet. Two devices, two engines, gossip.

let alice = QuiltMesh::new("alice");
let bob   = QuiltMesh::new("bob");

alice.set("counter", 1);
alice.gossip_with(&mut bob);
// bob.counter == 1
You're done. You built a value cell, a formula cell, a listener, a sensor, a router, time travel, and a mesh. That's Quilt. The cell is the universal IO. The sheet is the runtime. The mesh is the network.

Try the mesh live

Open this page in a second tab — your cells sync peer-to-peer.

→ Try the mesh
Step 1 of 7

Finished the tour? Try the Playground, or open Quilt Live and start building.