add mousedown event listener javascript code example Example: add mousedown event listener javascript object.addEventListener("mousedown", myScript);