- Owner
- justin
- Reviewed
- 2026-10-13
You need Node 24.
npm install
npm test # the transform, the room and simulated editors
npm run typecheck # the Worker and the page's script
npm run dev # builds the page script, then runs wrangler dev
npm run dev fetches wrangler through npx the first time. It serves the page and the Worker
on http://localhost:8787 with a local Durable Object and SQLite under .wrangler/.
Two editors
Open http://localhost:8787/#groceries in two windows side by side and type in both. The
status line shows the room's version, or "Saving" while an edit waits for its ack.
To see the note without the page:
curl http://localhost:8787/notes/groceries
Watching the protocol
The browser's developer tools show the frames on the socket under the Network tab, on the
ws request. You will see one op frame per send, an ack for each, and the other window's
ops arriving as op frames with a version. Wire protocol lists them.
Starting over
Delete .wrangler/state to forget every note.