Post

swiper 轮播

swiper 轮播

swiper 两组轮播图绑定

1
2
3
4
5
6
  this.$nextTick(() => {
    const swiperTop = this.$refs.swiperTop.swiper
    const swiperThumbs = this.$refs.swiperThumbs.swiper
    swiperTop.controller.control = swiperThumbs
    swiperThumbs.controller.control = swiperTop
  })

swiper 滚动至指定页

1
2
const swiperTop = this.$refs.swiperTop.swiper;
swiperTop.slideTo(index, 1000, false);
This post is licensed under CC BY 4.0 by the author.