WeChat applet loading detailed explanation and example code

高洛峰
Release: 2017-02-13 10:48:40
Original
1791 people have browsed it

This article mainly introduces the detailed explanation and example code of WeChat applet loading. Friends in need can refer to it

WeChat applet loading


Attribute name Type Default value Description
hidden Boolean false Whether to hide

Sample code:

<view class="body-view">
 <loading hidden="{{hidden}}">
  加载中...
 </loading>
 <button type="default" bindtap="loadingTap">点击弹出loading</button>
</view>
Copy after login

Page({
 data: {
  hidden: true
 },
 loadingTap: function(){
  this.setData({
   hidden: false
  });
  var that = this;
  setTimeout(function(){
   that.setData({
    hidden: true
   });
   that.update();
  }, 3000);
 }
})
Copy after login

Thank you for reading, I hope it can help everyone, thank you for your support of this site support!

For more WeChat applet loading, please pay attention to the PHP Chinese website for detailed explanations and sample code related articles!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!