prob: Detect all changes to a <input type=”text”> (immediately) using JQuery
Works without JQwery!
detect.js
var a;
function loop() {
console.log(document.getElementById("inp").value == a);
a = document.getElementById("inp").value;
requestAnimationFrame(loop);
}
requestAnimationFram(loop);
html
<script src="detect.js"></script>
<input type="text" id="inp"/>
I wanted to answer,so i did
New contributor
Ashton Drye is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.