Skip to content

Validation errors are not updated after config and field change #56

@meehaws

Description

@meehaws

Hi,

I have a dynamic content of my form, which is rendered based on type (it is provided from some drop down). Form inputs will change based on that type and so will do config.

What I observe after changing type to a different one, is that inside Validation component values:

  • fields will change to the new once
  • config will change to the new values
  • errors will stay as they were before changing type
<ValidatorsProvider validators={allValidators}>
                                <Form onSubmit={onSubmit} id={'someId'} className={classes.content}>
                                    <Validation config={selectConfigBasedOntype(type))}
                                                initialValues={defaults}>
                                        {generateDynamicFieldsBasedOnType}
                                    </Validation>
                                </Form>
                            </ValidatorsProvider>

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