Answers for "js get mouseclick"

2

js get mouseclick

function printMousePos(event) {
  document.body.textContent =
    "clientX: " + event.clientX +
    " - clientY: " + event.clientY;
}

document.addEventListener("click", printMousePos);
Posted by: Guest on August-25-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language