all input event listener code example
Example: javascript add event listener to all input
document
.querySelectorAll("input")
.forEach((elem) => elem.addEventListener("keyup", calculateSum));
document
.querySelectorAll("input")
.forEach((elem) => elem.addEventListener("keyup", calculateSum));