Skip to content
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

not working about validation #4156

Open
4 tasks done
hans000 opened this issue Apr 8, 2024 · 3 comments
Open
4 tasks done

not working about validation #4156

hans000 opened this issue Apr 8, 2024 · 3 comments

Comments

@hans000
Copy link

hans000 commented Apr 8, 2024

Prerequisites

What theme are you using?

core

Version

5.x

Current Behavior

Expected Behavior

Steps To Reproduce

  1. click submit button
  2. change input(neither click set button or type text can not cancel the error message)

https://codesandbox.io/p/devbox/rjsf-validate-gwrxj2

Environment

- OS:
- Node:
- npm:

Anything else?

No response

@hans000 hans000 added bug needs triage Initial label given, to be assigned correct labels and assigned labels Apr 8, 2024
@nickgros
Copy link
Contributor

Sorry, it's difficult to understand what your issue is. By default, validation only runs onSubmit. Is your issue resolved if you enable the liveValidate prop on Form, which triggers validation on change? liveValidate docs

@nickgros nickgros added question awaiting response validation and removed bug needs triage Initial label given, to be assigned correct labels and assigned labels Apr 12, 2024
@hans000
Copy link
Author

hans000 commented Apr 13, 2024

the liveValidate config is useful, but the initialization of the form to trigger the validation. UX is not very good.

@hans000
Copy link
Author

hans000 commented Apr 13, 2024

Prerequisites

What theme are you using?

core

Version

5.x

Current Behavior

Expected Behavior

Steps To Reproduce

  1. click submit button
  2. change input(neither click set button or type text can not cancel the error message)

https://codesandbox.io/p/devbox/rjsf-validate-gwrxj2

Environment

- OS:
- Node:
- npm:

Anything else?

No response

What I mean is that when there is a required form item, trigger the submit firstlly, and then after changing the value of the form item, the validation message can not be cancel.

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

No branches or pull requests

2 participants