Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clear event dispatcher now updates before emiting #332

Closed
wants to merge 1 commit into from

Conversation

EngHell
Copy link
Contributor

@EngHell EngHell commented Apr 19, 2023

As select and deselect, do update modelValue before emitting their respective events, clear now updates before emitting the clear event, to make it consistent.

This change is useful, because when you bind a listener to select or deselect you may easily use the ref passed to v-model, while for the clear event listener, v-model has not been yet updated which makes it complex to trigger other functions that rely on in the selected value, in my use case I have a reusable filter component that may spawn dozens of multiselect elements based of an array prop with configurations.

As `select` and `deselect`, do update `modelValue` before emitting their respective events, `clear` now updates before emitting the `clear` event, to make it consistent.
@EngHell
Copy link
Contributor Author

EngHell commented Apr 19, 2023

Closing this PR as it's from the wrong branch.

@EngHell EngHell closed this Apr 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant