Created
January 29, 2021 11:40
-
-
Save rndme/0847d056cfb979f610b2acb36f1e0bff to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function setClipboard(text) { | |
return navigator.clipboard.write( [new ClipboardItem({['text/plain']: new Blob([text], { type:'text/plain'}) })]); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment