跳到主要内容

DocumentChangeSpec

Defined in: document-sync.ts:20

一次文档替换的范围与内容,字段与 CodeMirror 的 ChangeSpec 兼容。

Properties​

from​

readonly from: number;

Defined in: document-sync.ts:22

替换起点(含)。


insert​

readonly insert: string;

Defined in: document-sync.ts:26

替换进去的文本。


to​

readonly to: number;

Defined in: document-sync.ts:24

替换终点(不含),基于替换前的文档坐标。