Skip to content

Add an event type prop #346

@dl-davi

Description

@dl-davi

I think it would be useful to implement an event type prop. When creating components (usually buttons), there are situations where different events should be triggered depending on how the component is used. Currently, this is not possible.

The workaround I am using is defining a prop with the image type. Since image props are generated as void*, I can later pass an event callback instead of an image pointer.

It would be cleaner and safer if the framework supported a dedicated event prop type that could be used to attach event handlers directly to components.

Metadata

Metadata

Assignees

No one assigned

    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