svelte: Svelte 5: Chrome: svelte-select list is not opened on the first click (same code of Svelte 4)
Firefox 126 works. Chrome 125 doesn’t.
The same code on Svelte 4:
https://svelte.dev/repl/cde634ff0a054288a0da1044cfd3d4eb?version=4.2.17
and on Svelte 5.0.0-next.136:
In the Svelte 5 the first click on the select doesn’t open the list.
I already opened https://github.com/rob-balfre/svelte-select/issues/690.
Severity
blocking an upgrade
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 21 (6 by maintainers)
I think someone should report it to Chrome, as this bug only occurs in Chrome – not even Edge. On the other-hand, we might be able to mitigate this in Svelte by attaching inline event handlers after we append to the DOM.
Update: we can’t really add events later, because it breaks the ordering with other directives like
bind:,use:andtransition:which both expect event handlers to have run in an order they understand. This is a tricky one for sure.That’s because we fixed it
Same as above, Canary 127.0.6490.0