Answers for "input events"

0

input events

const input = document.querySelector('input');
const log = document.getElementById('values');

input.addEventListener('input', updateValue);

function updateValue(e) {
  log.textContent = e.target.value;
}
Posted by: Guest on August-27-2021

Browse Popular Code Answers by Language