Skip to content

input tag with size=null crashes in Preact but not React #2284

@skvale

Description

@skvale

This works in React

<input size={null} />

But throws this error in Preact:

Uncaught DOMException: Failed to set the 'size' property on 'HTMLInputElement': The value provided is 0, which is an invalid size.

repo created from preact create default preact-input-size-null as an example: https://github.com/skvale/preact-input-size-null

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions