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 will introduce in detail "how to obtain system information in Mini Program development", the content steps are clear and detailed, and the details are handled properly, and the editor updates different knowledge points every day. I hope that this article "how to obtain system information in Mini Program development" can give you unexpected gains, please follow the editor's ideas slowly in depth, the specific contents are as follows, let's go to harvest new knowledge.
Get system information.
OBJECT parameter description:
The parameter type is required to indicate that successFunction is the callback function of successful API call failFunction No API call failed callback function completeFunction No callback function at the end of API call (both successful and failed calls will be executed)
Success callback parameter description:
Parameter description minimum version brand mobile phone brand 1.5.0model mobile phone model pixelRatio device pixel higher than screenWidth screen width 1.1.0screenHeight screen height 1.1.0windowWidth available window width windowHeight can use window height language Wechat set language version Wechat version number system operating system version platform client platform fontSizeSetting user font size setting. Subject to the settings in "I-Settings-General-Font size", unit: px1.5.0SDKVersion client Base Library version 1.1.0
Sample code:
Wx.getSystemInfo ({success: function (res) {console.log (res.model) console.log (res.pixelRatio) console.log (res.windowWidth) console.log (res.windowHeight) console.log (res.language) console.log (res.version) console.log (res.platform)}) what is the advantage of Mini Program compared with developers, Mini Program is less difficult to develop, can save development and operating costs, and allows developers to quickly develop a Mini Program. And Mini Program can be easily obtained and spread in Wechat, which can meet the basic life applications, in line with life services offline stores and non-rigid needs of low-frequency applications. For users, it can save time cost and mobile phone memory space, and have excellent use experience at the same time.
Thank you for reading this. The editor hopes that you will have the most profound experience from the practical level on the key issue of "how to obtain system information in Mini Program development". The specific usage also requires everyone to practice and use it in order to understand it. If you want to read more related articles, welcome to follow the industry information channel!
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.