Skip to content

Does not work with React Hook Form v7 FormProvider #52

Description

@manzoorwanijk

ErrorMessage uses V6 API, so we need to pass the errors prop to make it work in V7

const methods = useFormContext();
const error = get(errors || methods.errors, name);
if (!error) {
return null;
}

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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