Skip to content

TypeScript JSX focus events don't have consistent case #4289

@CodingDoug

Description

@CodingDoug

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

// Focus Events
onFocus?: FocusEventHandler<Target> | undefined;
onFocusCapture?: FocusEventHandler<Target> | undefined;
onfocusin?: FocusEventHandler<Target> | undefined;
onfocusinCapture?: FocusEventHandler<Target> | undefined;
onfocusout?: FocusEventHandler<Target> | undefined;
onfocusoutCapture?: FocusEventHandler<Target> | undefined;
onBlur?: FocusEventHandler<Target> | undefined;
onBlurCapture?: FocusEventHandler<Target> | undefined;

The four in question should probably be onFocusIn, onFocusInCapture, onFocusOut, and onFocusOutCapture.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions