`canSubmit` with `onMount` validators
Stackblitz reproduction.
Notice how the "Submit" button is not disabled, but the onMount validator returned an error (as shown next to the field).
I would expect canSubmit to return false when an onMount error is present instead of true like it does right now until the field is touched.
It seems wrong it's possible for the user to press submit without the form being in a valid state.
☁️ Nx Cloud Report
CI is running/has finished running commands for commit 39e9fa360fea18a90a31455178f2dc3d516a0480. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.
📂 See all runs for this CI Pipeline Execution
✅ Successfully ran 2 targets
Sent with 💌 from NxCloud.
commit: 39e9fa3
@tanstack/angular-form
pnpm add https://pkg.pr.new/@tanstack/angular-form@909
@tanstack/form-core
pnpm add https://pkg.pr.new/@tanstack/form-core@909
@tanstack/lit-form
pnpm add https://pkg.pr.new/@tanstack/lit-form@909
@tanstack/react-form
pnpm add https://pkg.pr.new/@tanstack/react-form@909
@tanstack/solid-form
pnpm add https://pkg.pr.new/@tanstack/solid-form@909
@tanstack/valibot-form-adapter
pnpm add https://pkg.pr.new/@tanstack/valibot-form-adapter@909
@tanstack/vue-form
pnpm add https://pkg.pr.new/@tanstack/vue-form@909
@tanstack/yup-form-adapter
pnpm add https://pkg.pr.new/@tanstack/yup-form-adapter@909
@tanstack/zod-form-adapter
pnpm add https://pkg.pr.new/@tanstack/zod-form-adapter@909
More templates
- @tanstack/form-example-angular-array
- @tanstack/form-example-angular-simple
- @tanstack/form-example-angular-valibot
- @tanstack/form-example-angular-yup
- @tanstack/form-example-angular-zod
- @tanstack/form-example-lit-simple
- @tanstack/form-example-lit-ui-libraries
- @tanstack/form-example-react-array
- @tanstack/form-example-react-next-server-actions
- @tanstack/form-example-react-query-integration
- @tanstack/form-example-react-simple
- @tanstack/form-example-react-tanstack-start
- @tanstack/form-example-react-ui-libraries
- @tanstack/form-example-react-valibot
- @tanstack/form-example-react-yup
- @tanstack/form-example-react-zod
- @tanstack/form-example-solid-array
- @tanstack/form-example-solid-simple
- @tanstack/form-example-solid-valibot
- @tanstack/form-example-solid-yup
- @tanstack/form-example-solid-zod
- @tanstack/form-example-vue-array
- @tanstack/form-example-vue-simple
- @tanstack/form-example-vue-valibot
- @tanstack/form-example-vue-yup
- @tanstack/form-example-vue-zod
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 88.55%. Comparing base (
5473bb8) to head (39e9fa3). Report is 157 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #909 +/- ##
==========================================
- Coverage 91.55% 88.55% -3.00%
==========================================
Files 21 26 +5
Lines 900 935 +35
Branches 206 208 +2
==========================================
+ Hits 824 828 +4
- Misses 71 101 +30
- Partials 5 6 +1
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Fixed with #726