-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The problem with enumerated
and Booleanish
#14301
Comments
This looks like an extension of #12664, which #13327 was supposed to fix - but turns out it didn't really, because we forgot about the static case. I'm not exactly sure what's the best way to deal with this is. We have a couple of options:
I'm torn between option b) and c) |
Yes, some errors can only be stumbled upon by accident. |
Ask the browser gods, we are as much scratching our heads as you
That seems to be a browser quirk where they allow |
I've studied the specification and I think I understand now:
|
I think option Option Option One other option, let's call it |
Describe the bug
There are several attributes whose values can be enumerated.
However, if the values are string representations of booleans, then the value type becomes
Booleanish
.svelte/packages/svelte/elements.d.ts
Line 730 in 320ebd2
This can lead to similar errors:
Reproduction
https://svelte.dev/playground/98dbee7e667d49028d0d7a662fd58f4e?version=5.1.16
Logs
No response
System Info
Severity
annoyance
The text was updated successfully, but these errors were encountered: