微信小程序 --- toast消息提示框

时间:2019-10-03 12:57:21   收藏:0   阅读:142

效果:

技术分享图片

<toast hidden="{{onOff}}" duration="1000" bindchange="clickTap" >默认</toast>

 

btnclick:function(){

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

具体参数

title:提示的内容。

icon:图标,只支持  success   loading

duration:提示的延迟时间,单位毫秒。

success:接口调用成功的回调函数

fail:接口调用失败的回调函数。

complete:主要调用接口的回调函数。

 

原文:https://www.cnblogs.com/lsyy2017/p/11619239.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!