-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
TypeScript JSX focus events don't have consistent case #4289
Comments
FYI: Preact supports all lowercase event name to align with the web. I think the |
@marvinhagemeister VSCode gives me an uncomfortable error if the JSX attribute doesn't match exactly. For example:
|
Yeah |
In my original message, I suggested that the definitions for these event attributes are incorrectly cased compared to the rest of the event attributes (scan the entire list in the file I cited - every single one of them is camel cased except for four of the focus events). I suggested alternatives that would bring them into consistency. I think I may have been unclear after that - I'm not saying that I want to use |
No, I was just giving historical context. We should support lowercased events like they are specced in web standards + camelCase. Might just be a matter of updating the type definitions in our JSX types. |
The focus events don't have consistent casing in their names with respect to other event attribtes:
preact/src/jsx.d.ts
Lines 1563 to 1571 in a003d42
The four in question should probably be
onFocusIn
,onFocusInCapture
,onFocusOut
, andonFocusOutCapture
.The text was updated successfully, but these errors were encountered: