@tanstack/form-core
Advanced tools
Comparing version 0.26.4 to 0.27.0
@@ -38,3 +38,3 @@ import { Store } from "@tanstack/store"; | ||
...prev, | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
errorMap: { ...prev == null ? void 0 : prev.errorMap, onMount: error } | ||
@@ -226,3 +226,3 @@ })); | ||
errorMap: { | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
...prev == null ? void 0 : prev.errorMap, | ||
@@ -229,0 +229,0 @@ [getErrorMapKey(cause)]: error |
{ | ||
"name": "@tanstack/form-core", | ||
"version": "0.26.4", | ||
"version": "0.27.0", | ||
"description": "Powerful, type-safe, framework agnostic forms.", | ||
@@ -40,5 +40,5 @@ "author": "tannerlinsley", | ||
"dependencies": { | ||
"@tanstack/store": "^0.5.4" | ||
"@tanstack/store": "^0.5.5" | ||
}, | ||
"scripts": {} | ||
} |
@@ -45,15 +45,6 @@ import { Store } from '@tanstack/store' | ||
TData extends DeepValue<TParentData, TName> = DeepValue<TParentData, TName>, | ||
> = TFieldValidator extends Validator<TData, infer TFN> | ||
? | ||
| TFN | ||
| FieldValidateFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: TFormValidator extends Validator<TParentData, infer FFN> | ||
> = | ||
TFieldValidator extends Validator<TData, infer TFN> | ||
? | ||
| FFN | ||
| TFN | ||
| FieldValidateFn< | ||
@@ -66,9 +57,19 @@ TParentData, | ||
> | ||
: FieldValidateFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: TFormValidator extends Validator<TParentData, infer FFN> | ||
? | ||
| FFN | ||
| FieldValidateFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: FieldValidateFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
@@ -107,15 +108,6 @@ /** | ||
TData extends DeepValue<TParentData, TName> = DeepValue<TParentData, TName>, | ||
> = TFieldValidator extends Validator<TData, infer TFN> | ||
? | ||
| TFN | ||
| FieldValidateAsyncFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: TFormValidator extends Validator<TParentData, infer FFN> | ||
> = | ||
TFieldValidator extends Validator<TData, infer TFN> | ||
? | ||
| FFN | ||
| TFN | ||
| FieldValidateAsyncFn< | ||
@@ -128,9 +120,19 @@ TParentData, | ||
> | ||
: FieldValidateAsyncFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: TFormValidator extends Validator<TParentData, infer FFN> | ||
? | ||
| FFN | ||
| FieldValidateAsyncFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
: FieldValidateAsyncFn< | ||
TParentData, | ||
TName, | ||
TFieldValidator, | ||
TFormValidator, | ||
TData | ||
> | ||
@@ -554,3 +556,3 @@ export interface FieldValidators< | ||
...prev, | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
errorMap: { ...prev?.errorMap, onMount: error }, | ||
@@ -884,3 +886,3 @@ })) | ||
errorMap: { | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
...prev?.errorMap, | ||
@@ -887,0 +889,0 @@ [getErrorMapKey(cause)]: error, |
@@ -40,5 +40,6 @@ import { Store } from '@tanstack/store' | ||
TFormValidator extends Validator<TFormData, unknown> | undefined = undefined, | ||
> = TFormValidator extends Validator<TFormData, infer TFN> | ||
? TFN | ||
: FormValidateFn<TFormData, TFormValidator> | ||
> = | ||
TFormValidator extends Validator<TFormData, infer TFN> | ||
? TFN | ||
: FormValidateFn<TFormData, TFormValidator> | ||
@@ -63,5 +64,6 @@ /** | ||
TFormValidator extends Validator<TFormData, unknown> | undefined = undefined, | ||
> = TFormValidator extends Validator<TFormData, infer FFN> | ||
? FFN | FormValidateAsyncFn<TFormData, TFormValidator> | ||
: FormValidateAsyncFn<TFormData, TFormValidator> | ||
> = | ||
TFormValidator extends Validator<TFormData, infer FFN> | ||
? FFN | FormValidateAsyncFn<TFormData, TFormValidator> | ||
: FormValidateAsyncFn<TFormData, TFormValidator> | ||
@@ -592,3 +594,3 @@ export interface FormValidators< | ||
) => { | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
const fieldInstance = this.fieldInfo[field]?.instance | ||
@@ -849,3 +851,3 @@ if (!fieldInstance) return [] | ||
): FieldInfo<TFormData, TFormValidator> => { | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
return (this.fieldInfo[field] ||= { | ||
@@ -852,0 +854,0 @@ instance: null, |
@@ -27,3 +27,3 @@ import type { FormApi } from './FormApi' | ||
// Prevent assigning undefined to target, only if undefined is not explicitly set on source | ||
// eslint-disable-next-line ts/no-unnecessary-condition | ||
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition | ||
if (!(sourceKey in source) && source[sourceKey] === undefined) { | ||
@@ -30,0 +30,0 @@ continue |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
416160
5579
Updated@tanstack/store@^0.5.5