Created
February 20, 2019 08:59
-
-
Save rotten77/4951c9a986899475193686db41a91842 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
var character = '👆'; | |
var temp_id = 'copypastecharacter-jsijfkjknkfd'; | |
document.body.innerHTML+='<input id="'+temp_id+'" value="'+character+'" />'; | |
var temp_elem = document.getElementById(temp_id); | |
temp_elem.select(); | |
document.execCommand('copy'); | |
temp_elem.parentNode.removeChild(temp_elem); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment