关于如何在手机/平板电脑上触发滚动事件(中滚动)也有类似的问题。我已经使用了下面提供的代码,但我还没有让它在 chrome 模拟器中工作。
$('body').on({
'touchmove': function(e) {
console.log($(this).scrollTop()); // Replace this with your code.
}
});
当我使用触摸传感器而不是 touchmove 滚动时,touchstart 将记录。我错过了什么?