当前位置:网站首页>Applet creation component
Applet creation component
2022-07-28 06:55:00 【Like Feynman%】
1. Create components

1.2 Local reference component
// page .json file
{
"usingComponents": {
"test1":"/components/test/test1"
}
}
// page .wxml file
<text>pages/list/list.wxml</text>
<view></view>// Force a line break
<test1></test1>
1.3 Global application ( stay app.json Configuration in file )
1.4 Global references vs Local application
According to the frequency and range of components , Choose the right way
- If a component is often used on multiple pages , Recommended “ Global references ”
- If only used on a specific page , Recommended “ Local application ”
1.5 Differences between components and pages
On the surface , Components and pages are made up of .js .json .wxml .wxss These four documents consist of . however , Components and pages .js And .json There are obvious differences between documents :
- Component's .json Declaration required in document “component:true” attribute
- Component's .js What is called in the file is Component() function
- The event handler function of the component needs to be defined to methods In nodes
边栏推荐
- Which is the best one to make air conduction headphones? Inventory of the best air conduction headphones
- Which brand of air conduction earphones is good and highly praised
- Technology sharing | how to do Assertion Verification in interface automated testing?
- Gerapy use
- 等保3.0-服务器三权分立配置
- [C language] custom structure type
- 网络——传输层(详细版)
- 软件测试(概念篇)
- NFS 共享存储服务
- Hdu-1159-commonsubsequence (LCS longest common subsequence)
猜你喜欢

Technology sharing | interface testing value and system

Technology sharing | common proxy tools for interface testing

Technology sharing | detailed explanation of actual combat interface test request methods get, post

Mongo SSL configuration practice
![Implementation of simple address book in [c language]](/img/75/8f2f4dd1c166808047cda6bea5a746.png)
Implementation of simple address book in [c language]

MySQL主主

LNMP搭建过程详解

How about air conduction Bluetooth headset? It's the most worthwhile air conduction headset to start with

C language memcpy library functions and the role of memmove

On cookies and session
随机推荐
yapi漏洞挂马程序chongfu.sh处理
DNS域名解析服务
raid磁盘阵列
JS four operations are repackaged to solve the problem of precision loss
NAT和PAT的原理及配置
Skimming records -- sequence traversal of binary tree
单元测试框架Jest搭配TypeScript的安装与配置
Pku-2524-ubiquitous relations (parallel search template)
技术分享 | 接口测试常用代理工具
SSH服务配置
Array to linked list
Compilation and preprocessing of C language
Qgraphicsview promoted to qchartview
遍历 二叉树
Which brand of air conduction earphones is good and highly praised
Network - network layer
Technology sharing | do you know the functions of the server interface automated testing and requests library?
Build php7 private warehouse
测试面试题集锦(三)| 计算机网络和数据库篇(附答案)
网络——传输层(详细版)