We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
undo
redo
1 parent 0279086 commit 34844ecCopy full SHA for 34844ec
packages/core/src/editor/BlockNoteEditor.ts
@@ -1056,6 +1056,20 @@ export class BlockNoteEditor<
1056
return replaceBlocks(this, blocksToRemove, blocksToInsert);
1057
}
1058
1059
+ /**
1060
+ * Undo the last action.
1061
+ */
1062
+ public undo() {
1063
+ this._tiptapEditor.commands.undo();
1064
+ }
1065
+
1066
1067
+ * Redo the last action.
1068
1069
+ public redo() {
1070
+ this._tiptapEditor.commands.redo();
1071
1072
1073
/**
1074
* Insert a piece of content at the current cursor position.
1075
*
0 commit comments