current position:Home>Vue parent component calls child component method

Vue parent component calls child component method

2021-08-23 00:55:42 Love and sorrow of Grey Wolf

1. development environment vue
2. computer system windows10 pro
3. In the process of development , When we have some situations , Need to be in Methods of using child components in parent components , Now let me share how to use it .
4. I don't say much nonsense , Go straight to the code :

//  Parent component code 
<Ca :UpLoad="OrderList.UpLoad" ref="child" />
//  Subcomponent code :
GetCa() {
    return this.Ca;

5. Subcomponent method is invoked in parent component


6. The sharing of this issue is over here , I hope it helped you , Let's work together to get to the top .

copyright notice
author[Love and sorrow of Grey Wolf],Please bring the original link to reprint, thank you.

Random recommended