You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 14, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Oct 14, 2026. It is now read-only.
error message doesn't seems to work in usefieldarray #90
For my case, yup resolver was causing the issue. (I was using Custom Hook with ResolverShown in this docs )
To address the problem,
I switched to using the @hookform/resolvers package.
However, I also discovered that using square brackets instead of a dotted name can resolve the issue.
For example, instead of test.${index}.lasttname, you can use test[${index}].lastName when defining the name property for a Controller component.
This may be a simpler solution for some cases.
This works because the square brackets align with the name that Yup uses.
Activity
dd8888 commentedon Jan 31, 2023
I got it working by doing this:
simonpeters commentedon Apr 21, 2023
has anyone got this fixed? above solution doesn't work for me.
iamjaydev commentedon Apr 29, 2023
For my case, yup resolver was causing the issue. (I was using
Custom Hook with ResolverShown in this docs )To address the problem,
I switched to using the @hookform/resolvers package.
However, I also discovered that using square brackets instead of a dotted name can resolve the issue.
For example, instead of
test.${index}.lasttname, you can usetest[${index}].lastNamewhen defining the name property for a Controller component.This may be a simpler solution for some cases.
This works because the square brackets align with the name that Yup uses.
Hope it helps someone