Skip to content

Support for MUI Text Field #45

@prince272

Description

@prince272
// Consider using a dyamic component: Example
export const DynamicComponent = forwardRef(({ as, children, ...props }, ref) => {
    const Component = as;
    return (<Component ref={ref} {...props}>{children}</Component>);
});

// Use case: The TextField is a MUI component 
<DynamicComponent  as={TextField} />

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions