jonathan.costin
← All projects

Web app

Ajaia Docs

A collaborative document editor. Several people edit one document live, with named cursors, sharing as editor or viewer, version history and .docx import.

  • React
  • TipTap
  • Yjs
  • Hono
  • Cloudflare Workers
  • Durable Objects
  • D1
  • Playwright
Two people in one document, with Bob's named cursor visible to Alice
Two people in one documentLive app

What it does

  • Create, rename, edit and delete documents. Changes save about a second after you stop typing.
  • Several people edit one document at once. Each sees the others' text and cursors arrive as they type, and two people typing in the same paragraph merge cleanly.
  • The owner shares a document as Can edit or Can view, changes a role or removes access.
  • Import .txt, .md and .docx files, read and restore earlier versions, and export to Markdown.

How access works

The server enforces roles, on the live connection too. A viewer sees edits arrive, but the server drops anything their browser sends. A user without access can't tell the document exists. A role change takes effect at once, even for someone who has the document open.

How it's tested

The API and live-editing tests run inside the Workers runtime against a real D1 database and real sockets into the Durable Object. They check every cell of the access table, that a viewer's edits are dropped and that a forged role is ignored. Playwright runs the whole flow with three people in three browsers, and CI runs it all on every push.

Try it

The login page has a one-click button for each of three test accounts. Open the same document as two of them, one in a private window, to see live editing.