I have this line of code that works when I'm using the paste event:
//This works
document.addEventListener('paste', e => {
console.log("e.clipboardData.getData('text/plain');",
e.clipboardData.getData('text/plain'));
});
But I need to copy and paste with a button so:
//Not Working
jQuery(buttonId).click(e => {
console.log("e.clipboardData.getData('text/plain');",
e.clipboardData.getData('text/plain'));
});