rob-balfre / svelte-select

Svelte Select. A select component for Svelte
https://svelte-select-examples.vercel.app
Other
1.25k stars 175 forks source link

on:input not firing correctly #507

Closed gmrizzo closed 1 year ago

gmrizzo commented 1 year ago

I was wondering why the event on:input didn't get called. After I looked into it, I found that the event is only triggered on the change of the selection, like described in the change event. Is there a fault in the description of the documentation, or did I just misunderstand it?

rob-balfre commented 1 year ago

@gusi1994 hopefully this REPL will help explain...

https://svelte.dev/repl/ef663e0d1a2f4743aa1306983f087ef6?version=3.55.0

See: https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/change_event https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/input_event