Replies: 3 comments 1 reply
-
What So if you want to use this behavior, you have to pass one such object (maybe custom, maybe just |
Beta Was this translation helpful? Give feedback.
-
Okay, that makes a lot of sense. My main dilemma is, how do I access Event on a custom emit?
Would this call for creating my own Event class inheriting from
If an event instance already exists for custom events, I'd like to know how to access it. I didn't see that in the docs |
Beta Was this translation helpful? Give feedback.
-
Yeah, I am familiar with that part. Essentially, for my use case, and anyone else searching for this:
Thanks again, I didn't know that all |
Beta Was this translation helpful? Give feedback.
-
I'm trying to create a component that has a fallback option of opening a link in a new tab. And was hoping there would be a way to define such functionality.
Use Case
I have a child element
external-link
such as:I have a parent element such as:
By default, the the 'open' event should open a tab in the browser (which is code I already have for).
But if on the parent component, the developer states
@open.prevent="someFunc"
, theprevent
stops a new tab from opening.The part I cannot do, is specify a handler on the
external-link
component that gets prevented when theprevent
modifier is used.If this functionality already exists, then I'd change this request to a documentation update request.
Beta Was this translation helpful? Give feedback.
All reactions