【问题标题】:jQuery Mobile swipe event not workingjQuery Mobile 滑动事件不起作用
【发布时间】:2018-08-07 14:00:09
【问题描述】:

目前我正在尝试开发自己的支持手势的轮播。支持非常简单 - 当用户向左或向右滑动时会触发相应的功能。但是,左右滑动时不会触发事件。 我的笔在那里https://codepen.io/CrUsH20/pen/yvQxKE 之后我导入了 jQuery 和 jQuery Mobile。但我没有得到任何结果。我的功能接近底部,然后是评论。 函数看起来如此

$($this).on('swipeleft', function(event) {
    scrollToNext();
});
$($this).on('swiperight', function(event) {
    scrollToPrevious();
});

【问题讨论】:

    标签: jquery jquery-mobile gesture


    【解决方案1】:

    发现问题。 jQuery Mobile 1.5 需要 jQuery 2.1 而我使用的是 3.xx

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-02-14
      • 2014-04-22
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多