html52.com
我爱小程序-开发者交流社区

小程序scroll-view下拉刷新在数据结束时再返回刷新ios底部会有一段空白

框架类型 问题类型 操作系统 操作系统版本 手机型号 微信版本
小程序 Bug iOS 原生小程序 苹果13 8.0.20

这是正常表现形态这是iOS到数据底部再下拉刷新返回到底部这是正常表现形态

这是正常表现形态

这是正常表现形态这是iOS到数据底部再下拉刷新返回到底部

这是iOS到数据底部再下拉刷新返回到底部

网友回复

社区技术运营专员-Jahozheng:

请具体描述问题出现的流程,并提供能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。

aaa:
 <scroll-view scroll-y refresher-enabled="{{scroll_refresher_enabled}}" refresher-threshold="45" refresher-default-style="none" refresher-background="#fff" refresher-triggered="{{showLoading}}" bindrefresherrefresh="scrollRefresh" style=" height: {{scrollviewHeight}}px;" bindscroll="inscrollMOve" scroll-top="{{scrollTop}}" bindscrolltolower="scrollBottom" >


 // scroll-view下拉刷新
  scrollRefresh() {
    if(!this.data.showLoading){
      this.fetchProducts(this.data.currentCategory.secondId, true)
      this.setData({ 
        showLoading: true 
      })
      this.stopScrollRefresh()
    }
  },
  stopScrollRefresh(){
    if(this.data.showLoading == true){//如果刷新状态为true置为false
      var _this = this;
      setTimeout(()=>{
        _this.setData({
          showLoading: false,
          scrollTop:0
        })
      },1000)
    }
  },

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

真正的个人免签约支付接口

云免签H5支付