试读部分
打开首页,然后点击第一个按钮进去心得页面 进入心得页面以后 第一个模块是轮播图用的是swiper组件,然后就是四个按钮绑定点击事件,最后就是下拉刷新,下拉滚动,上拉加载。代码顺序wxml,js,wcss,json。 <!--pages/one/one.wxml-->
<navigation-bar title="牧原" back="{{false}}" color="black" background="#FFF"></navigation-bar>
<scroll-view scroll-y="{{true}}" style="width:100%;height:1000rpx;" bindscrolltolower="lower">
<view>
<swiper autoplay circular>
<block wx:for="{{banners}}" wx:key="acm">
<swiper-item>
<image mode="widthFix" src="{{item.image}}"></image>
</swiper-item>
</block>
</swiper>
<view>
<text>
初始化numbers为:{{numbers}}
</text>
</view>
<view class="btn1">
<button bindtap = "onClickBtn">
按钮
</button>
<block wx:for="{{btns}}" wx:key="*this">
<button bindtap="btn" style="background-color: {{……
本文为 VIP 文章,已展示部分内容,
开通 VIP 后查看全文
觉得这篇文章有帮助?
点个赞,或赞赏支持作者持续创作