Back to Plate

Slate v2 Final API Hard Cuts Status

docs/slate-v2/final-api-hard-cuts-status.md

53.0.63.7 KB
Original Source

Slate v2 Final API Hard Cuts Status

Current Read

The final API posture is not “legacy Slate React with faster internals”.

The kept shape is:

  • data-model-first slate
  • editor.read / editor.update
  • transaction/commit-first local execution through primitive editor methods
  • projection-source overlays
  • semantic Editable
  • extension editor, state, and tx groups
  • generated browser gauntlet proof for cursor/caret claims

Hard Cut Matrix

CutStatusCurrent stateRemaining owner
Keep decorate out of the primary APIdonePrimary Editable has no decorate prop. Projection stores are the overlay API. Legacy callback-style decoration is only available through the explicitly named createSlateDecorateCompatSource adapter.None for primary API. Keep compat adapter narrow.
Keep child-count chunking deaddoneProduct slate-react runtime has no renderChunk, getChunkSize, or child-count chunking API. Huge docs use semantic islands, active corridor, occlusion, and projection stores.None for product runtime. Legacy chunking remains only as historical/comparison context.
Cut mutable editor fields from primary public APIdone for public teachingeditor.children, editor.selection, editor.marks, and editor.operations are not primary read paths. Public docs/examples/tests use read APIs, transaction/update APIs, and focused helpers instead. Internal runtime storage is not app/plugin DX.Final type-surface deletion remains tied to package/runtime compatibility pressure, not primary docs.
Stop teaching editor.apply / editor.onChangedone for public teachingExamples do not monkey-patch editor.apply; huge-document instrumentation uses Editor.subscribe; extension power is through editor, state, and tx groups plus commit listeners. Direct apply/onChange replacement is not an extension point.Final low-level compatibility deletion remains tied to package/runtime compatibility pressure.
Hard-cut dead legacy React renderer exports/tests/docsdoneLegacy renderer exports DefaultElement, DefaultLeaf, and DefaultText are removed. Old renderer files and the broad legacy decorations test are deleted. Current public primitives are Editable, EditableText, SlateElement, SlateLeaf, SlateText, TextString, ZeroWidthString, and related semantic primitives.Local docs may use DefaultElement as an example-local function name; that is not a package export.

Not Done

Final release closure still needs same-turn verification:

  • bun test:integration-local
  • package build/typecheck/lint gates
  • React/core perf guardrails
  • completion-check closure

The browser editing architecture is under the conformance kernel contract:

  • event-frame authority
  • selection-source authority
  • mutation-worker boundaries
  • repair-result ownership
  • generated replayable gauntlets
  • scoped mobile/native transport claims

Execution owner:

Proof Pointers