Multiplayer canvas (Figma-style)
Live design-tool multiplayer: delta-CRDT maps per file, a session actor as ordering authority, 60Hz cursor presence, and a compacted changelog.
What this design does
Figma's trick is treating the file as a big CRDT map of objects — each property update is a tiny delta that merges cleanly, so fifty cursors can edit one canvas without locks. A per-file session actor orders and rebroadcasts deltas, the changelog persists them with aggressive compaction (only the latest value per property matters), and presence traffic stays ephemeral. The same shape runs our own live collab on techdiagrams.net.
The patterns it composes
- Delta-CRDT map — per-property last-writer merge — object moves are tiny commuting deltas
- Virtual actor per file — one addressable session owns ordering for one document
- WebSocket connection gateway — sticky routing muxes thousands of sockets to file sessions
- Changelog compaction — history collapses to latest-per-property; joins stay fast
- Presence — cursors at 60Hz are ephemeral — never persisted, never replayed
Import it, attach your own numbers, and verify the design against failures — or read the engineering notes.