Skip to content

fix: create fieldMeta on async validation for fields with errors#2056

Open
literalpie wants to merge 2 commits intoTanStack:mainfrom
literalpie:literalpie/async-validation-unmounted
Open

fix: create fieldMeta on async validation for fields with errors#2056
literalpie wants to merge 2 commits intoTanStack:mainfrom
literalpie:literalpie/async-validation-unmounted

Conversation

@literalpie
Copy link

🎯 Changes

This updates the validateAsync function to have similar logic to validateSync. See #1691 where this logic was added to validateSync.

This makes it so that if async validation results in errors, any fields with errors will have a fieldMeta created

Fixes #2033

✅ Checklist

  • I have followed the steps in the Contributing guide.
  • I have tested this code locally with pnpm test:pr.

🚀 Release Impact

  • This change affects published code, and I have generated a changeset.
  • This change is docs/CI/dev-only (no release).

This updates the validateAsync function to have similar logic to validateSync. See TanStack#1691 where this logic was added to validateSync.

Fixes TanStack#2033
@changeset-bot
Copy link

changeset-bot bot commented Mar 2, 2026

🦋 Changeset detected

Latest commit: 0868ac1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 13 packages
Name Type
@tanstack/form-core Patch
@tanstack/angular-form Patch
@tanstack/form-devtools Patch
@tanstack/lit-form Patch
@tanstack/react-form Patch
@tanstack/solid-form Patch
@tanstack/svelte-form Patch
@tanstack/vue-form Patch
@tanstack/react-form-devtools Patch
@tanstack/solid-form-devtools Patch
@tanstack/react-form-nextjs Patch
@tanstack/react-form-remix Patch
@tanstack/react-form-start Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fieldMeta not set by async validator

1 participant