html5 ontouchmove事件实现移除元素classname 帮我看看代码有什么问题

2025-03-01 15:54:28
推荐回答(1个)
回答1:

既然使用jQuery了,为什么这么绕呢:
$('.test').on('touchmove', function() {
if ($(this).hasClass('hover')) $(this).removeClass('hover');
});