fix wysiwyg event cleanup (#1248)

pull/1255/head
David Luzar 5 years ago committed by GitHub
parent 290244660b
commit 81b38d8808
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -139,6 +139,12 @@ export function textWysiwyg({
}
function cleanup() {
// remove events to ensure they don't late-fire
editable.onblur = null;
editable.onpaste = null;
editable.oninput = null;
editable.onkeydown = null;
window.removeEventListener("wheel", stopEvent, true);
document.body.removeChild(editable);
}

Loading…
Cancel
Save