wx.showToast的complete执行顺序问题?

发布于 7 年前作者 guiying3413927 次浏览最后编辑 7 年前来自 ask
  • 当前 Bug 的表现(可附上截图)

wx.showToast中的complete声明周期一开始就执行

  • 预期表现

不应该是延时结束的时候执行吗?

  • 复现路径

  • 提供一个最简复现 Demo

wx.showLoading()

setTimeout(() => {

wx.hideLoading({

success: () => {

wx.showToast({

title: ‘success’,

icon: “success”,

duration,

complete: () => {

console.log(“???”)

}

})

}

})

}, 3000)

2 回复
xiuyingfeng
xiuyingfeng1 楼6 年前

确实有这个bug

xia87
xia872 楼5 年前

给compelete执行的内容一个duration的setimeout呗