当前位置:网站首页>Pass parent component to child component: props
Pass parent component to child component: props
2022-07-07 07:09:00 【To be a woman of light】
One 、 Communication between parent components is very common in development , For example, the parent component has some data , Sub components are required for presentation ;
- At this time we can adopt props To complete the communication between components ;
Two 、 What is? Props Well ?
- Props Yes, you can on the component Register some custom attribute;
- Parent component to these attribute assignment , Subcomponent pass attribute Get the corresponding value from the name of ;
3、 ... and 、Props There are two common uses :
- Mode one : Array of strings , The string in the array is attribute The name of ;
- Mode two : object type , The object type can be specified in attribute Name at the same time , Specify the type it passes , Is it necessary 、 Default value and so on ;
Mode one : Dynamic data should be colon

Mode two :

边栏推荐
猜你喜欢

毕业设计游戏商城

Please answer the questions about database data transfer

Bus message bus

2018年江苏省职业院校技能大赛高职组“信息安全管理与评估”赛项任务书

基于JS的迷宫小游戏

Precise space-time travel flow regulation system - ultra-high precision positioning system based on UWB

服装门店如何盈利?

SolidWorks GB Library (steel profile library, including aluminum profile, aluminum tube and other structures) installation and use tutorial (generating aluminum profile as an example)

Data of all class a scenic spots in China in 2022 (13604)

Config分布式配置中心
随机推荐
选择商品属性弹框从底部弹出动画效果
请教一下,监听pgsql ,怎样可以监听多个schema和table
Graduation design game mall
Tool class: object to map hump to underline underline hump
from . onnxruntime_ pybind11_ State Import * noqa ddddocr operation error
Sqlserver multithreaded query problem
大咖云集|NextArch基金会云开发Meetup来啦
Bus message bus
Multidisciplinary integration
RuntimeError: CUDA error: CUBLAS_ STATUS_ ALLOC_ Failed when calling `cublascreate (handle) `problem solving
服装门店如何盈利?
一文带你了解静态路由的特点、目的及配置基本功能示例
请问 flinksql对接cdc时 如何实现计算某个字段update前后的差异 ?
Learning records on July 4, 2022
The startup of MySQL installed in RPM mode of Linux system failed
[explanation of JDBC and internal classes]
Distributed ID solution
from .onnxruntime_pybind11_state import * # noqa ddddocr运行报错
oracle如何备份索引
. Net core accesses uncommon static file types (MIME types)