Skip to content

Build your personal knowledge base with Trilium Notes

resetting the editor after note load - not complete solution because ctrl-z will revert to initial editor state

azivnera2d174665b99
diff --git a/static/js/note.js b/static/js/note.js
index b3a642ef0c..a1c32f8cc5 100644
--- a/static/js/note.js
+++ b/static/js/note.js
@@ -162,6 +162,9 @@ function loadNote(noteId) {
noteChangeDisabled = true;
+ // Clear contents and remove all stored history. This is to prevent undo from going across notes
+ $('#noteDetail').summernote('reset');
+
$('#noteDetail').summernote('code', noteText);
document.location.hash = noteId;