striven-editor

Maintained and contributed to an open source WYSIWYG editor as an internship project that made it to production and was adopted by the company I was working at.
git clone https://unitehenry.com/git/striven-editor.git
Log | Files | Refs | README | LICENSE

commit ef9c2c29e65dfa04954bbf00dba7e22791531dc8
parent b435027e69ba7cbafe43ca751de2c62e52a9a338
Author: unitehenry <unitehenry@gmail.com>
Date:   Wed,  6 Nov 2019 15:06:11 -0500

demo

Diffstat:
Mdemo/src/App.vue | 7++++++-
1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/demo/src/App.vue b/demo/src/App.vue @@ -47,7 +47,12 @@ export default { d: "M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z" }, - handler: () => console.log('hello') + handler: () => { + const range = this.editor.range; + if(range && range.startContainer !== document) { + range.insertNode(document.createTextNode('Created by a custom button!')) + } + } } ], placeholder: "Begin typing in this editor...",