Answers for "prevent paste in input"

0

prevent paste in input

window.onload = () => {
 const myInput = document.getElementById('myInput');
 myInput.onpaste = e => e.preventDefault();
}
Posted by: Guest on August-04-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language