预览:
源码:
let box = document.querySelector(".box"); box.ontouchstart = function (){ console.log("start"); } box.ontouchend = function (){ console.log("end") }