How can I forward event from a custom Listbox component on v2.0? #155
Unanswered
shamscorner
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Since the
on:change
event is removed from theListbox
component, I am not sure how can I forward it to it's parent from child. Here is my implementation:Consider this
FormSelect.svelte
file:Note: consider the script tag is there and also some other implementations.
On another file:
Now the problem is: if I have 3
FormSelect
components, all are forwarding that change-event even if I don't attachon:change
on the other components. My guess is it is binding the value to the ListBox by reference somehow and it is updating for all components that means thatonChangePackageType
method is calling for all the otherFormSelect
components.Any suggestions would be much appreciated.
Beta Was this translation helpful? Give feedback.
All reactions