Skip to content

请问在vue3中该如何在子组件中判断emit注册的方法父组件是否传入呢? #8092

Discussion options

You must be logged in to vote

你可以参考v-model的原理在结合一下jsx中的写法推导出 @change =>onChange

demo

Replies: 5 comments 4 replies

Comment options

You must be logged in to vote
4 replies
@tiandaixin
Comment options

@chenxch
Comment options

@dywedzfc
Comment options

@baiwusanyu-c
Comment options

Answer selected by tiandaixin
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
8 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy