-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
issue: register function don`t return options with shouldUseNativeValidation in 7.44.0 or later #10504
Comments
Sorry, I misunderstood the situation. This change was intended and not a breaking change. The implementation ensures that native validation correctly even without returning the option. |
So, my case - is this a bug or not? I updated the sendbox to see that the properties are not being passed to input. The form is not submitted if the conditions are not met, but there are no native error messages either. Also, the type of the If version 7.44.3 behaves correctly in this case, does it mean that when the |
There was a bug fix, please refer to the comment above. |
Ok, is it possible to get the default native error messages without passing a custom property Also, react-hook-form/src/types/form.ts Line 166 in 747ddca
At the same time, if a |
|
Just FYI related #10492 |
Just got stumped by this, only ended up here after looking through source code - far as I can tell the |
Version Number
7.44.3
Codesandbox/Expo snack
https://codesandbox.io/s/react-hook-form-7-44-3-4vm9w2?file=/src/App.tsx
Steps to reproduce
register
function doesn't return passed propertiesrequried
,min
, and any otherExpected behaviour
In version 7.43.9 (sandox here) the function
register
withshouldUseNativeValidation: true
option returned the passed parameters and I expected this behavior in my code. In 7.44.3 this is not the case. Why has it changed?What browsers are you seeing the problem on?
No response
Relevant log output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: