I want to execute the command:
document.execCommand("paste");
on Javascript. But it always returns only false!
The console.log
in the example below shows the text "false"!
document.querySelector("button").onclick = () => {
document.querySelector("input").focus();
console.log("execCommand('paste') returns", document.execCommand("paste"));
};
<button>paste</button>
<input type="text">