In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly explains "analyzing the code composition developed by Android WeChat Mini Programs". The content of the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "analyzing the code composition developed by Android WeChat Mini Programs".
One JSON configuration file
01, app.json is the current global configuration of Mini Program, including all page paths, interface performance, network timeout, bottom tab, etc., of Mini Program.
02, page.json page level configuration
03, project.config.json tool configuration, Mini Program developer tool-related configuration attributes, do not quite understand
Two WXML templates
Similar to HTML, only the tags are different. Mini Program's WXML uses tags such as view, button, text and so on. These tags are the basic capabilities that Mini Program wraps for developers. We also provide map, video, audio and other component capabilities.
WXML just show, JS only content, build MVVM development pattern, similar to Vue development concept, such as introducing a field
{{msg}}
JS only needs to manage the status:
This.setData ({msg: "Hello World"})
Binding a variable to the interface through the syntax of {{}} is called data binding. Data binding alone is not enough to fully describe the relationship between state and interface, but also requires control capabilities such as if/else and for. In Mini Program, these control capabilities are expressed by attributes at the beginning of wx:
Three WXSS style
WXSS has most of the features of CSS, and Mini Program has also made some extensions and repairs in WXSS.
Four logical interactions
In Mini Program, we deal with users' operations by writing JS script files.
{{msg}} Click me
When we click the button button, we want to display the msg on the interface as "Hello World", so we declare a property on button: bindtap, and declare the clickMe method in the JS file in response to this click:
Page ({clickMe: function () {this.setData ({msg: "Hello World"})}) Thank you for your reading. The above is the content of "analyzing the Code composition developed by Android WeChat Mini Programs". After the study of this article, I believe you have a deeper understanding of the problem of analyzing the code composition developed by Android WeChat Mini Programs, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.