Skip to content
Source
Sign inSign up
TanStack/form

fix(react-form): accept extendForm forms in base withFieldGroup components #2412

Opendasjideepak(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/2412/headopened

Showing 4 changed files with 8 additions and 3 deletions (loading 1).

x
0 of 4 viewed, 4 left
5 additions and 0 deletions.changeset/wide-fields-extend.mdAdded
View file
@@ -0,0 +1,5 @@
+---
+'@tanstack/react-form': patch
+---
+​
+Allow passing a form from `extendForm` to a field group made with the base hook's `withFieldGroup`
2 additions and 2 deletionspackages/react-form/src/useField.tsxModified
View file
@@ -498,7 +498,7 @@
| FormAsyncValidateOrFn<TParentData>,
in out TFormOnServer extends undefined | FormAsyncValidateOrFn<TParentData>,
in out TPatentSubmitMeta,
- in out ExtendedApi = {},
+ out ExtendedApi = {},
> = <
const TName extends DeepKeys<TParentData>,
TData extends DeepValue<TParentData, TName>,
@@ -555,7 +555,7 @@
export type LensFieldComponent<
in out TLensData,
in out TParentSubmitMeta,
- in out ExtendedApi = {},
+ out ExtendedApi = {},
> = <
const TName extends DeepKeys<TLensData>,
TData extends DeepValue<TLensData, TName>,
1 addition and 1 deletionpackages/react-form/src/useFormGroup.tsxModified
View file