Chrome provides a copy(myCopyObj)
to copy an object. Do we have anything similar in terms of pasting an object or getting the contents from the clipboard?
"Getting the contents from clipboard"
Execute the following on devtools side and within 3 seconds focus on the window (by clicking somewhere, or just hitting <tab>
).
setTimeout(async()=>console.log(await window.navigator.clipboard.readText()), 3000)
This will just print the clipboard content. You can replace console.log with code that actually uses the clipboard content.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With