-
Notifications
You must be signed in to change notification settings - Fork 81
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
fix multi select error never shown #166
Conversation
hi @jannikbuschke , I fixed a small issue for multi select error not shown when submit, hope for your approval |
Hi @jannikbuschke |
} | ||
const hasError = error !== undefined && isTouched | ||
const hasInitialError = initialError !== undefined | ||
const isValid = !error && isTouched | ||
const showHelp = | ||
hasError || | ||
(hasInitialError && (!isTouched || showInitialErrorAfterTouched)) | ||
console.log('Line 36', showHelp, error, isTouched) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@linchen2chris Seems like debug code, that should be removed
@linchen2chris please update your merge request, this bug is annoying, let's get rid of this. |
Ill try to close this this weekend |
@allcontributors add linchen2chris for code |
I've put up a pull request to add @linchen2chris! 🎉 |
I used the code here in commit 11269b2 |
if a field is array of string/number, when submit formik will set its
isTouched
to [], then formik-antd will set it to 'false' and its error will never shown.