vue引用swiper在chrome浏览器下报

网上找到很多人说修改 css  touch-action: none; 可以解决此问题,此方案未解决。

[Intervention] Ignored attempt to cancel a touchmove event with cancelable=false, for example becaus

swiper.js?82ca:2795 [Intervention] Ignored attempt to cancel a touchmove event with cancelable=false, for example because scrolling is in progress and cannot be interrupted.
onTouchMove @ swiper.js?82ca:2795

 

于是找到 swiper原文件,node_modules=》swiper 下面的 swiper.js,第2795行 屏蔽  // e.preventDefault();,不再报错了。

swiper.allowClick = false;

// e.preventDefault();

if (params.touchMoveStopPropagation && !params.nested) {

e.stopPropagation();

}

相关文章:

  • 2021-07-15
  • 2021-08-08
  • 2021-10-14
  • 2021-06-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-02
猜你喜欢
  • 2021-11-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-14
相关资源
相似解决方案