Skip to content

CodeMirrorEditorOperation

Unofficial

The batch of work an editor is in the middle of. Nested operations share one of these, and the editor only reacts to what happened once the outermost one ends.

Import:

import type { CodeMirrorEditorOperation } from '@obsidian-typings/obsidian-catalyst-latest';

Signature:

export interface CodeMirrorEditorOperation

Properties

PropertyTypeDescription
$dnumberHow deeply operations are currently nested. The operation ends when this reaches zero.
changes?ChangeSetThe document changes made so far during this operation, used to map positions taken before them.
cursorActivity?booleanWhether the cursor moved during this operation.
deletedText?stringThe text deleted during this operation.
isVimOp?booleanWhether this operation was started by the Vim layer.
lastChange?unknownThe most recent change made during this operation.

Links to this page: