vue-awesome-swiper icon indicating copy to clipboard operation
vue-awesome-swiper copied to clipboard

某些app的webview会出现切换卡顿的问题

Open fangge opened this issue 7 years ago • 1 comments

在使用过程中,swiperOption如果只是单纯设置了

swiperOption: {
          nextButton: '.swiper-button-next',
          prevButton: '.swiper-button-prev',
          pagination: '.swiper-pagination'
}

在某些app的webview里面,在最初和最末页还可以切换,但是会卡一下,然后才恢复成原状,可以根据swiper官方的解释,加上兼容设置来防止这种问题

swiperOption: {
          nextButton: '.swiper-button-next',
          prevButton: '.swiper-button-prev',
          pagination: '.swiper-pagination',
          loop:false,
          mode: 'horizontal',
          freeMode:false,
          touchRatio:1,
          longSwipesRatio:0.1,
          threshold:50,
          followFinger:false,
          observer: true,//修改swiper自己或子元素时,自动初始化swiper
          observeParents: true,//修改swiper的父元素时,自动初始化swiper
        }

fangge avatar Jan 13 '18 13:01 fangge

现在依然存在这个问题,按照上面的方法配置的话会出现滑动不顺畅

qingchenmengzhong avatar Dec 17 '20 11:12 qingchenmengzhong