小程序BindTap快速连续点击页面跳转多次

原因:

  手机端点击Tap基础事件解决300ms延迟

解决办法: 

  success 里面加一个延迟300ms能解决 setTimeout

  goRob(e) {
    const that = this
    return (function() {
    clearTimeout(that.timer)
      that.timer = setTimeout(() => {
        wx.navigateTo({
          url: '/pages/money?type=rob' + '&formId=' + (e.detail.formId || '')
        })
      }, 300)
    })()
  }

推荐网址:

变量控制:https://www.jianshu.com/p/adb8b42fc3f0

延时300ms:https://blog.csdn.net/xdongll/article/details/51908994

原文地址:https://www.cnblogs.com/zhaomeizi/p/9764907.html