You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$(iframeBody).on("paste", '[contenteditable="true"]', function (e) {
console.log('paste')
e.preventDefault();
var text = e.originalEvent.clipboardData.getData('text');
console.log('text to past: ', text);
e.target.ownerDocument.execCommand("insertText", false, text);
});
It looks correct to me, even though the post is from back in 2017.
When testing this in a basic setup, with just this as init,
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
When using this snippet I found on this post
It looks correct to me, even though the post is from back in 2017.
When testing this in a basic setup, with just this as init,
I am able to reproduce this.
Not sure if this a bug, or I am just looking at it the wrong way. Thanks for any help!
Beta Was this translation helpful? Give feedback.
All reactions