-
-
Notifications
You must be signed in to change notification settings - Fork 26
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
Add debounce on reload-listener.js #222
base: main
Are you sure you want to change the base?
Conversation
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.
Did you test this? It looks like it won’t work as the debounce calls won’t share the timer. Also testing would help find an appropriate timeout.
Please also add a changelog note. |
So the debounce function is executed but not the timeout, my guess is that is something that in a worker act differently... |
So for my investigation the debounce doesn't work as it is inside a sharedworker, so the timer is resetted everytime and not kept in memory. |
Other thread that confirms that the shared worker doesn't remember the previous timeout so the debounce doesn't work: |
I’m pretty sure the client-side debounce will work, because the worker process is long-lived. This PR currently edits Keeping open so you or I or someone can pick it up. |
I don't have time to work on that so this is why I closed it as there is already a ticket about it. |
Ref: #22
I am not sure about the ms for the debounce.