weui用Toast组件显示Loading
在JQuery WEUI的官网(http://jqweui.com/components#toast)没有看到有显示Loading的用法,只有其他的用法,这里都给大家贴出来。
官网已有的用法:
$.toast("操作成功");
$.toast("取消操作", "cancel"); $.toast("禁止操作", "forbidden"); $.toast("纯文本", "text"); // 第二个参数可以是时间,单位毫秒 $.toast("消息", 20000);
官网没有提到的用法,显示Loading:
$.showLoading("数据加载中")
关闭Loading:
$.hideLoading()
效果为:
附:weui官网的链接
国外:http://jqweui.com(需用vpn)
国内:https://jqweui.cn(最近很卡)