R
fn

applyTransaction

tested

Produce the next editor state from a transaction. Stored marks are kept when explicitly set, cleared on any content change, and otherwise preserved.

Signature

ts
export function applyTransaction(state: EditorState, tr: Transaction): EditorState{ ... }

Parameters

ParameterTypeDescription
stateEditorState
trTransaction

Returns

EditorState