diff --git a/docs/api/operation.md b/docs/api/operation.md index f803a42e1..47eec745d 100644 --- a/docs/api/operation.md +++ b/docs/api/operation.md @@ -2,6 +2,18 @@ `Operation` objects define the low-level instructions that Slate editors use to apply changes to their internal state. Representing all changes as operations is what allows Slate editors to easily implement history, collaboration, and other features. +- [Static methods](operation.md#static-methods) + - [Manipulation methods](operation.md#manipulation-methods) + - [Check methods](operation.md#check-methods) + +## Static methods + +### Manipulation methods + +#### `inverse(op: Operation) => Operation` + +Invert an operation, returning a new operation that will exactly undo the original when applied. + ### Check methods #### `isNodeOperation(value: any) => boolean` @@ -23,9 +35,3 @@ Check if a value is a `SelectionOperation` object. Returns the value as a `Selec #### `isTextOperation(value: any) => boolean` Check if a value is a `TextOperation` object. Returns the value as a `TextOperation` if it is one. - -### Static methods - -#### `inverse(op: Operation) => Operation` - -Invert an operation, returning a new operation that will exactly undo the original when applied.