-
Notifications
You must be signed in to change notification settings - Fork 118
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
fix(select): select check additional count event loop #743
Conversation
This still not a very viable solution, it is running multiple times for one selection. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After testing it, I've experienced that the _checkAdditionalItemCount method is now running only once per selection, am I missing anythng? Additionally, during the initial load it runs 3 times. We might consider optimizing the registerOption method and lifecycles to reduce these initial runs in the future. However, I believe this implementation meets our current needs well.
ps: Let's not forget to create an issue for potential future enhancements.
We could accept this as a workaround, but this is still problematic. It should and only run once when an option is selected/removed, unfortunately rerenders are effecting this and causing to run more than necessary. |
🎉 This PR is included in version 2.4.0-beta.2 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 3.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Fixes select causing the window to be frozen on choosing x amount of options. This is caused by running
_checkAdditionalItemCount
within updated for each update instead of listening for selected options only.