You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to create a form validator, and I encountered a bug when it does not change the $state of values on the first keypress inside <CustomInput/>
This should be relative to the fact that you are adding an oninput that is already added by bind:value if you move the bind:value after the spread it works fine
I think that make sense, this mean I don't need bind:value at all? I can do something like this ?
What seems weird to me is that it works in firefox and not in chrome, and moving function getProps from class change the behaviour too. I will make the issue open and wait on maintainers what they say, if there is some bug or not.
I've investigated a bit further and apparently the bug happens when you modify (inside the oninput) the same property that you are returning next to it (in this case this.errors[name]) definitely some weird behavior here.
Describe the bug
I am trying to create a form validator, and I encountered a bug when it does not change the $state of
values
on the first keypress inside<CustomInput/>
This is smallest code that reproduce that bug:
Things I found:
getProps()
outsideForm
class.Reproduction
https://svelte-5-preview.vercel.app/#H4sIAAAAAAAAA6VTTWvbQBD9K4-lIBmEfFckQwkEcik55RLloMjjeKm0K3ZHNkXov5fZVWS77qFQdNHsm48382YmddAdeVW8Tco0PalCfR8GlSn-NYjhT9QxqUx5O7pWXkrfOj3wrjaA7gfrGI-jZ9s_m2FkHJztkeTbYOUxPHmojbi3XeM9nqzrMYkNnJpuJI8K3zw3TOk0bx4iQs5Zd4fUXHPEW2s8u7Fl69IJ2mjWTfca082br_wAH7XP1zI3fkulOZIDPolfnB18KoO4SuGIR2cuNmCNlvYKpLRBtRMoMAtfqBjpv0mmd1Solbc98VGbz1pd8szZ5T9EFLiLXl3mC9-VdEeMg8yzgqFzGG268LxptcAEyVYgSZaqYZ7ldlWzHIKkT9p5RntsXNMyOWgPYxmyDntog9i4RIp_bcpr8Yeuaelouz25qlYRiRG1woc2-yIoUU3CeVElF14zpjzPw-uqQiJAspmxXdk9M87W_fQ4az7CNKxP9AejUv-FyY8rz_9lUhuVqd7u9UHTXhXsRpqz9XjCHP7hfLD7ku_6EmTdhVzz0VG6yeJWhWVYtiDPc0eeBZjFeQj8ws3cihmncGk0dCWh0sR9A-_zb84yRwEJBAAA
Logs
No response
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: