Skip to content

FormProps interface doesn't support custom props. #864

@matiosfree

Description

@matiosfree

What is the current behavior?

With TypeScript there is an error, when I app extra props.

<Form component={FormComponent} onSubmit={handleSubmit} onCancel={handleCancel} />

Property 'onCancel' does not exist on type 'IntrinsicAttributes & FormProps<any, Partial<{ firstName: string; }>>'.

What is the expected behavior?

There should not be any error.

What's your environment?

"@types/react": "^16.9.49",
"react-final-form": "^6.5.1",

Other information

For the FieldRenderProps we have:
[otherProp: string]: any;

Seems like we need the same for FormProps

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions