sveltejs / svelte · Issue No. 18447
The difference in behavior between <input> and <select> with regards to defaultValue is confusing. I can use value and bind:value on both, but for <select> I have to add selected to the child <option> element instead of using <select defaultValue="foo">?
This also makes remote form resetting difficult to implement in sveltekit (see https://github.com/sveltejs/kit/issues/16093), because <select {...form.fields.select.as('select', 'default')}> cannot add selected to the child options.
Add the parity (make <select defaultValue="foo"> work).
<select value="foo"><option>foo</option></select> already compiles to <select><option selected="">foo</option></select>, so adding support shouldn't be too difficult I hope.
would make my life easier
Relay reads this issue against the repository's contribution signals: the files it is likely to touch, how the maintainers triage work this size, and what the first contribution would exercise.
The full analysis for this issue is still being assembled. Until then, the description above and the thread on GitHub are the most reliable context.