Describe the bug
If you have an input and then rerender your view with another autofocused input, then autofocus does not seem to work. I see this bug in Chrome and Firefox, but in Safari it seems to work fine.
Reproduction
Just click button multiple times in this REPL.
<script>
let input = $state(0)
</script>
<button onclick={() => (input++)}>click</button>
{#key input}
<input type="text" placeholder={input} autofocus />
{/key}
System Info
Firefox 135.0 (20250130195129)
Chrome 133.0.6943.53 (Official Build) (arm64)
Safari 18.3 (20620.2.4.11.5)
Severity
annoyance