0
点赞
收藏
分享

微信扫一扫

Swiper轮播插件

m逆光生长 2022-03-30 阅读 88

swiper是一款轻量级轮播图插件,

<view class="banner">
  <swiper class="swip_main" indicator-dots autoplay interval="6000" circular>
    <block wx:for="{{mglist}}">
      <swiper-item>
        <image style="width: 100%;height:100%;" mode="aspectFill" src="{{item.photo}}"></image>
      </swiper-item>
    </block>
  </swiper>
</view>

indicator-dots:面板指示点,布尔属性
autoplay:自动播放属性,指定加载网页时
interval:定时器,每隔interval指定的时间就执行事件一次
circular:是否采用衔接滑动

举报

相关推荐

0 条评论