Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
hunghg255 authored Jul 25, 2024
1 parent a9ee886 commit e643ba1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,15 @@
});

quill.on("text-change", (a, b, c) => {
localStorage.setItem("content", quill.root.innerHTML);
document.getElementById("prev").innerHTML =
quill.scroll.domNode.innerHTML;
});

const content = localStorage.getItem("content");
if (content) {
quill.root.innerHTML = content;
}
})
</script>

Expand Down

0 comments on commit e643ba1

Please sign in to comment.