specificationa. The page file follows the vue single file component specification<!-- Template block --> <template> <view class="main"> {{msg}} </view> </template> <!-- Script Block --> <script> export default { data(){ return { msg:'Hello' } } } </script> <!-- Style block --> <style> .main{ background-color:#ccc; } </style> b. Component labels are close to the mini-program specifications<template> <view>hello</view> <text> wang </view> </template> c. Interface capabilities (JS API) are close to WeChat Mini Program specifications//Get location informationuni.getLocation({ type:'wgs84', success:function(res){ console.log('Current location longitude: '+res.longitude); console.log('Current location latitude: '+res.latitude); } }); e. Data binding and event handling use Vue.js specifications<template> <view @click="changeMsg"> {{msg}} </view> </template> <script> export default{ data(){ return { msg:'hello' } }, methods:{ changeMsg(){ this.msg:'world' } } } </scrip> featurea. Conditional compilation#ifdef APP-PLUS Code that only appears on the APP platform#endif #ifndef H5 Except for the H5 platform, the code that exists on other platforms#endif #ifdef H5 || MP-WEIXION Code that exists on the H5 platform or WeChat Mini Program platform#endif b. Nvue development on the App side The uni-app App has a built-in native rendering engine based on Weex, which provides native rendering capabilities. On the App side, if you use the vue page, use webview rendering; if you use the nvue page, use native rendering. c. HTML5+The uni-app App has a built-in HTML5+ engine, allowing js to directly call on rich native capabilities. Some more complex functions can be implemented by directly calling the App's native plug-ins. Can only be used on the App side, not on H5 and mini programs SummarizeThis article ends here. I hope it can be helpful to you. I also hope that you can pay more attention to more content on 123WORDPRESS.COM! You may also be interested in:
|
<<: XHTML introductory tutorial: Use of list tags
>>: How to use Docker to package and deploy images locally
How can we say that we should avoid 404? The reas...
1. HTML Overview htyper text markup language Hype...
Run the script in debug mode You can run the enti...
1. First, you need to use the target selector of ...
Exporting Data Report an error SHOW VARIABLES LIK...
Solution to MySQLSyntaxErrorException when connec...
The upload form with image preview function, the ...
Today I will share with you a source code contain...
need: In the near future, we will implement the l...
1. Download the Linux version from the official w...
In the MySQL documentation, MySQL variables can b...
This technique comes from this article - How to a...
Anyone who has read my articles recently knows th...
1. How to create a user and password 1. Enter the...
Method 1: Adding values Let's go to MDN to se...