关注我们: 微信公众号

微信公众号

电脑用户请使用手机扫描二维码

手机用户请微信打开后长按二维码 -> 识别二维码

微信小程序:交互反馈 API 说明

IT技术 2017-03-03 1964

wx.showtoast(object)

显示消息提示框
object参数说明:
[tr]参数类型必填说明[/tr]

title String 提示的内容
icon String 图标,只支持"success"、"loading"
duration Number 提示的延迟时间,单位毫秒,默认:1500, 最大为10000
success Function 接口调用成功的回调函数
fail Function 接口调用失败的回调函数
complete Function 接口调用结束的回调函数(调用成功、失败都会执行)

示例代码:

wx.showToast({
    title: '成功'icon: 'success',
    duration: 2000
}) wx.hideToast()

关键词:

网友留言2

未查询到任何数据!
◎欢迎您留言咨询,请在这里提交您想咨询的内容。