Skip to content
Edytor
Esc
↑↓navigate↵open⌘Jpreview
On this page

Limitations

What edytor does not provide, what is not finished, and the known edge cases of collaborative editing.

Edytor’s collaboration stack is proven by its test suites across Chromium, Firefox and WebKit, but it has no production track record yet. This page lists what is out of scope, what is not built, and the edge cases you may meet; Platform support lists the browsers, devices and input methods the suites run, and what they do not (real phones, operating-system IMEs). The screen-reader passes the accessibility page lists are not recorded yet.

Not provided

  • No hosted infrastructure. Edytor ships the Durable Object room; you deploy and operate it on your own Cloudflare account. There is no edytor cloud.
  • No authentication or permission rules. No accounts, sessions, sharing model or roles. The room calls your authorize and enforces what it returns (user, replica, access level), nothing more.
  • No backups or document management. The room stores one document in its Durable Object’s SQLite storage. Listing, exporting, backing up and deleting documents are up to your application (document.encode() and facade.toJSON() give you the content). The room’s version history keeps two versions a day for 30 days, in the store you choose (KV, R2, the room’s own storage or one of your own): it is not a backup. Versions kept in the room’s own storage go with its Durable Object, and a version larger than its store’s value limit is skipped.
  • IndexedDB is not durability. The local copy lives in the browser and can be cleared by the user or the browser. Durable storage is the room’s.

Not finished

  • Simple tables only. The table plugin is Notion’s simple table: cells of text, no merged cells, no cell selection, no sorting, filters or formulas, and no database views. A text range across cells deletes each cell’s covered text; copy of a part of a table copies its text.
  • Comments are plain text. The comments plugin keeps threads on text ranges with replies, resolve and reopen, stored by the room. A comment has no formatting, mentions or attachments, cannot be edited once posted, and anchors to text only (not to a block). A read identity reads threads but writes none; a comment one comments without editing.
  • Version history is two versions a day. The room keeps two versions a day, and the history panel lists, previews (with the blocks added, removed and changed since) and restores them; there is no per-edit timeline (see History and purge below).
  • Suggestions. A view-local suggestion (an AI draft) shows only in the view that made it until it is accepted, and a reload loses it; a shared one is in the document for everyone, and needs the shared suggestions plugin in every view of the document: a view without it shows their text as plain content, exports it and edits it directly. Only text and blocks are suggested (a merge, a retype, a data change, a format, a move, a nest or an outdent is refused while the view suggests), and exports (edytor.value, onSave’s value, a cross-document move) leave pending suggestions out, at the cost of a copy of the document while any is pending. Reviewing needs a view with the plugin: a document without one (a server, a bot) leaves them out of toJSON() once adoptSharedSuggestions built them over it, reads them only through toJSON({ suggestions: true }), and cannot list, accept or reject them. For a suggest-only user, a plugin’s own writes (a bookmark’s unfurl, a page link’s title) are refused by the room. See its limitations.
  • No property schema. Properties take any JSON; validate or normalize in onBeforeOperation.
  • Columns have no colours of their own. A columns layout resizes with the pointer or, on a focused gap, with the arrow keys.
  • An array item written by index is the item at that index. A patch that names an item by index (['tags', '2']) writes whatever item is there when it runs, after a collaborator inserted or removed one above it; name it by its id (document.dataItemIds(id, ['tags'])) for rows several people edit. See Properties.

Localization

The package’s words (the kinds’ names, placeholders, announcements) come from a labels dictionary, English by default, which <Edytor labels> replaces entry by entry; your chrome’s words are your markup’s. Edytor ships no translation of its own: write the dictionary for your language, typed as Labels, so a release that adds a label fails your build until you translate it.

  • Your own kinds, marks, commands and groups are named by what you write in their records.
  • Mac key symbols (⌘, ⇧, ↵) show on a Mac whatever the labels.
  • The chrome is placed for a left-to-right page. Blocks take their own text’s direction (Right-to-left text); the menus, toolbar and handles keep their left-to-right layout and placement in a right-to-left page.

Mixed-version peers

  • Clients of different document generations never exchange edits: providers and the room refuse the other’s frames and report 'protocol-mismatch' or 'schema-mismatch'. Deploy one version to every client.
  • Older clients of the same generation ignore the per-person delete and undo records. They show a block whose creation was undone (empty, or with another person’s text); their own undo still deletes a block outright; and a text deleted by two people and undone by both can appear twice on them. A current client may also bring back text it held back after an old client deleted it, since an old client’s delete carries no record.
  • Clients from before properties were stored per leaf read a block’s or inline block’s data only from its old whole-value attribute: after a current client writes a property there, they show the value from before it, and they do not see the document’s properties. Clients from before array items were stored per item read an array a current client wrote as an object keyed by its items’ ids.
  • Clients of an earlier pre-release have no layout role: they show a stored columns layout as unknown kinds, its blocks one under the other, and apply none of its rules (an empty column or a one-column layout a current client would hide shows there). A current view without createColumnsPlugin() shows a layout the same way. Deploy the plugin to every view before your users make layouts.
  • Clients that predate the saved and chunk messages report them through 'message-error' and otherwise sync small documents normally.
  • A server that never sends saved acknowledgements leaves the provider’s unsaved count growing; one that acknowledges only state vectors leaves delete-only updates unsaved.

Offline first visit

A device whose first visit to a document happens offline seeds the value you passed (after the readiness bound) and keeps that seed. When it reconnects, the seed merges into the room’s content. Seeds are deterministic, so pass the same value everywhere (or none) and equal seeds merge into one; a different value adds its blocks next to the room’s. To avoid it, set requireHydration: the view stays read-only and seeds nothing until the document was fetched once. To have documents ready before a device goes offline, prefetch them.

The WebSocket’s bound starts when the socket opens (or first fails to), so a room that is slow to accept the connection is waited for, up to the connect timeout. Two cases remain:

  • A server that opens the socket but takes more than 1 s to send its state is treated like an empty room: the value is seeded and later merges as above.
  • A dial that neither opens nor fails (a connection the network silently drops, or a room still loading) is given up after connectTimeout (10 s by default), so an empty document waits up to 11 s before it seeds. For rooms whose load can take longer, raise connectTimeout in createWebsocketSync, or set it to Infinity to wait as long as the browser does.

Known edge cases

  • Undo of text deleted twice. When two people delete the same text, it comes back only when both undo. If one of them has closed their session, their replica no longer hides a concurrent restoration, although their delete still holds back later undos.
  • Text typed and deleted within one undo step leaves nothing to restore.
  • Two splits at the same position. Both new lines exist; the text goes to one and the other stays empty.
  • Line order in two races. Lines two people paste into one gap from both sides (a list, a code block, a divider or an image pasted at the start of a line, and one pasted at the end of the line above) can show in either order, by client id; so can lines a single unNestBlocks call outdents when they are not adjacent, against another person’s outdent next to them. The other races the tests run between splits, pastes, new lines, outdents, lifts, Turn into and moves keep the text order on every pair of client ids, except a split racing a move of the same block and the list edge cases. See which races keep the text order, splits and joins next to a moved block and lists.
  • Undoing a split joins the halves again, even if someone typed in the second half. See concurrent editing.
  • Contributors are block lineage, not authorship. attribution.block(id).contributors lists who edited that block id (through splits and merges too), not who wrote the text shown now.
  • A read-only view syncs read-only. A readonly view with room and server (or sync) connects and shows peers’ edits live, and writes nothing; the room decides what an identity may write (access in authorize). A readonly view with the shared suggestions plugin still shows the pending shared suggestions.
  • saved after a reload. The provider counts what the document’s actor wrote, recognized by the client ids the document binds to that actor. Without an actor, the anonymous id changes every session, so edits made before a reload no longer count in unsaved. A delete restored from the local copy counts only when its update wrote no other author’s content, since a delete does not record who made it.
  • Columns: a selection dragged over the bare gap. Dragging a text selection from column 1 into the gap between two columns never selects column 2, but past the gap’s middle (over the gap itself, not a block’s handle) it extends to the end of column 1.
  • Columns: Escape from the block menu opened on a block in a column gives back a caret, not the block selection.
  • Columns: native ↑/↓ move visually and differ per engine (Firefox from column 1’s last line goes below the layout, Chromium and WebKit into column 2); see Columns.
  • One user per browser profile. The local copy and the cross-tab channel are shared by every tab of a profile; see persistence.

Size and platform limits

  • A document’s stored size grows with every edit. About 22 bytes an edit in the soak’s mix of 50 writers typing, splitting, merging and deleting (about 14 with 8 writers), for the document’s life: the CRDT structure each edit leaves. The purge gives back about a tenth of it in that mix (about 20 bytes an edit after it with 50 writers, 13 with 8), as most of what it deletes is text; it gives back more where whole blocks were deleted (see the purged block below). A document many people edit every day reaches the 2 MiB default in weeks; past the quota the room refuses writes (4413) and the provider stops, its later edits unsaved. The maximum document size is yours to choose: raise EDYTOR_MAX_DOCUMENT_BYTES as far as the room’s memory allows (below), and watch the room’s size log, written when a document reaches 80 % of it (EDYTOR_DOCUMENT_WARNING). Past half the quota the room re-seeds the document from its content, back to what its content takes, when nobody wrote for ten minutes (see re-seeds below).
  • Long pages type slower. The editor renders every block, with no windowing. Its own work for a key does not grow with the page, but the browser’s does: in Chromium, each keystroke makes it walk the text of the whole editable root for the input method, and lay out a root of thousands of blocks (a character takes about 6 ms at 1,000 blocks and 24 ms at 5,000; Enter 13 and 54 ms). Keep a document to a couple of thousand top-level blocks for typing within a frame; see Long pages.
  • A room document is capped at 2 MiB stored by default (about 4,500 paragraphs of prose): the room holds the live document in an isolate of 128 MB, where it takes 15 to 77 times its stored size (a long list of short blocks is the most per byte). Raise the quota for documents of long text; split very long lists of short blocks across documents. A single WebSocket message is capped at 32 MiB by Cloudflare; both the provider and the room send larger frames as chunks. The image plugin refuses an inline (data:) image over 1 MiB: upload it instead.
  • Document ids and user ids are 1 to 256 characters, and a user id with a lone surrogate is refused 4403 (see authorize). A document id may hold any character: the provider percent-encodes it into one path segment, and your Worker decodes it (see the quick start). The ids . and .. are the exception, and so is an id with a lone surrogate: a URL collapses those segments (%2E too) and cannot encode a lone surrogate, so the provider throws for them and routeDocumentSocket closes them 4400.
  • After a room wakes from hibernation, presence refills as clients renew it, within 15 seconds.
  • Deleted content stays in the document so undo and offline peers keep working: a withdrawn block keeps its node (about 75 bytes), and each text delete adds about 6 bytes to the stored document. Compacting the room’s rows stores the live document, which drops deleted text no one can restore, but keeps what undo and offline peers may still need.
  • Deleted content is purged after 30 days (purgeAfterDays). A purged block leaves its id behind (about 6 bytes stored, compressed). A purged line split from a paragraph that is still there (Enter makes most lines so) shares that paragraph’s text, so it also leaves the mark where its text was and what its text leaves (about 35 bytes stored, compressed, for a line of 300 characters). A deleted block a visible one still depends on — a block moved into a deleted one shows in its place — keeps its bare structure (its kind, place and delete marks, about 20 bytes stored, compressed). Its text and properties are purged all the same.
  • A version over its store’s value limit (KV’s 25 MiB, R2’s 128 MiB, the room’s own 32 MiB) is skipped, not split; versions are two a day, and only one restore can be undone, until the next restore or the purge horizon.

Re-seeds

  • Every client reloads the document once. A re-seed closes every socket; a view that owns its document builds itself again on the new epoch, so its selection, scroll position and undo history start over (an app that passes its own document builds the new one).
  • Concurrent restructuring of the same blocks. An offline client’s text edits merge exactly. When both sides split, merged or deleted the same blocks meanwhile, the result can differ from what the edits would have made without the re-seed, for a few characters: text typed into a block one side then deleted, which a split from the other side would have kept, stays deleted; a block merged into one the other side deleted does not come back. About 1 % of the characters differ in tests where a third of the edits on both sides restructure the same few blocks; none is duplicated.
  • Order and marks at one spot. Two inserts made at one place on both sides can come out in the other order, and a mark the other side applied can end a character earlier or later.
  • Pending suggestions wait for the re-seed’s next idle period, and are dropped by one forced past 80 % of the quota. An offline client’s own pending suggestions are dropped when it hands its edits over, and a suggest-only user’s offline work (all suggestions) with them; an accept or reject it made offline of one the re-seed dropped is lost too.
  • Clients before 7.0 are refused by a room that re-seeded (1008, refused: epoch); an offline client’s edits are dropped after 30 days (closed 4410, its copy deleted).
  • The instant of the hand-over. What a user types between handing its edits over and the room’s 4410 (about one round trip) is lost when the copy is deleted.
  • A tab that took an older epoch’s content from another tab of the same browser (before that tab reloaded) is closed 4410 when it sends it, and what it typed since is lost with its copy.
  • Blocks moved to another room before a re-seed are no longer watched for late edits: an offline client’s edit to one is lost.
  • A tab kept open without a connection holds its local copy’s database: another tab of the profile that heard the re-seed waits for it to close before its new copy opens.

History and purge

  • Two versions a day, not every edit. The history keeps the state at local noon and midnight of each half-day that changed; finer history is the per-block attribution and the undo history.
  • A restore undone revives with the room’s delete. A restore that brought back a block someone deleted, then undone, deletes it again as the room: that person’s own undo of their delete no longer brings it back (restore a version instead).
  • An undo older than 30 days restores nothing. Once the room’s purge passed it, an undo history drops the step.
  • A device offline past the purge horizon keeps its edits to content that still exists; its edits to content purged meanwhile (typed into a block deleted 30 days ago and more) are dropped, a block it moved under a purged block shows at the top level, and a split of such a block keeps no text. See the purge.

Was this page helpful?