simple-syntax-highlighter
simple-syntax-highlighter copied to clipboard
Not backward compatible, somwhere between 3.0.3 and 3.1.1 method copyCode was removed
Can I ask you bring back copyCode method or give an alternative to this in order to use custom positioning for external buttons?
copyCode(t) {
t.target.insertAdjacentHTML(
"afterend",
`<textarea id="clipboard-textarea">${this.$refs.code.innerText}</textarea>`
);
const e = document.getElementById("clipboard-textarea");
e.select(), e.setSelectionRange(0, 99999), document.execCommand("copy"), e.remove(), this.$emit("copied", this.$refs.code.innerText);
}
Right now, this is missing and it's causing problems.