Created
February 5, 2023 08:38
-
-
Save egorvinogradov/4f9180083251a6110df54d9555c00093 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
javascript:(function(text){ | |
let textarea = document.querySelector('form textarea'); | |
let event = new Event('input', { bubbles: true }); | |
let nativeInputValueSetter = Object.getOwnPropertyDescriptor(HTMLTextAreaElement.prototype, 'value').set; | |
nativeInputValueSetter.call(textarea, text + '\n\n' + textarea.value); | |
textarea.dispatchEvent(event); | |
})('--- TEXT ---') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment