Skip to content

Commit 0a21e96

Browse files
ci: apply automated fixes and generate docs
1 parent f10f43e commit 0a21e96

File tree

2 files changed

+63
-11
lines changed

2 files changed

+63
-11
lines changed

docs/reference/classes/fieldapi.md

Lines changed: 28 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,28 @@ The current field state.
175175

176176
## Methods
177177

178+
### clearValues()
179+
180+
```ts
181+
clearValues(opts?): void
182+
```
183+
184+
Defined in: [packages/form-core/src/FieldApi.ts:1319](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1319)
185+
186+
Clear all values from the array.
187+
188+
#### Parameters
189+
190+
##### opts?
191+
192+
`UpdateMetaOptions`
193+
194+
#### Returns
195+
196+
`void`
197+
198+
***
199+
178200
### getInfo()
179201
180202
```ts
@@ -231,7 +253,7 @@ Use `field.state.value` instead.
231253
handleBlur(): void
232254
```
233255
234-
Defined in: [packages/form-core/src/FieldApi.ts:1661](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1661)
256+
Defined in: [packages/form-core/src/FieldApi.ts:1670](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1670)
235257
236258
Handles the blur event.
237259
@@ -247,7 +269,7 @@ Handles the blur event.
247269
handleChange(updater): void
248270
```
249271
250-
Defined in: [packages/form-core/src/FieldApi.ts:1654](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1654)
272+
Defined in: [packages/form-core/src/FieldApi.ts:1663](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1663)
251273
252274
Handles the change event.
253275
@@ -357,7 +379,7 @@ parseValueWithSchema(schema):
357379
| StandardSchemaV1Issue[]
358380
```
359381
360-
Defined in: [packages/form-core/src/FieldApi.ts:1703](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1703)
382+
Defined in: [packages/form-core/src/FieldApi.ts:1712](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1712)
361383
362384
Parses the field's value with the given schema and returns
363385
issues (if any). This method does NOT set any internal errors.
@@ -385,7 +407,7 @@ parseValueWithSchemaAsync(schema): Promise<
385407
| StandardSchemaV1Issue[]>
386408
```
387409
388-
Defined in: [packages/form-core/src/FieldApi.ts:1715](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1715)
410+
Defined in: [packages/form-core/src/FieldApi.ts:1724](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1724)
389411
390412
Parses the field's value with the given schema and returns
391413
issues (if any). This method does NOT set any internal errors.
@@ -497,7 +519,7 @@ Replaces a value at the specified index.
497519
setErrorMap(errorMap): void
498520
```
499521
500-
Defined in: [packages/form-core/src/FieldApi.ts:1678](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1678)
522+
Defined in: [packages/form-core/src/FieldApi.ts:1687](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1687)
501523
502524
Updates the field's errorMap
503525
@@ -622,7 +644,7 @@ Updates the field instance with new options.
622644
validate(cause, opts?): unknown[] | Promise<unknown[]>
623645
```
624646
625-
Defined in: [packages/form-core/src/FieldApi.ts:1621](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1621)
647+
Defined in: [packages/form-core/src/FieldApi.ts:1630](https://github.com/TanStack/form/blob/main/packages/form-core/src/FieldApi.ts#L1630)
626648
627649
Validates the field value.
628650

docs/reference/classes/formapi.md

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,36 @@ Defined in: [packages/form-core/src/FormApi.ts:830](https://github.com/TanStack/
131131
132132
## Methods
133133
134+
### clearFieldValues()
135+
136+
```ts
137+
clearFieldValues<TField>(field, opts?): void
138+
```
139+
140+
Defined in: [packages/form-core/src/FormApi.ts:2131](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2131)
141+
142+
Clear all values within an array field.
143+
144+
#### Type Parameters
145+
146+
• **TField** *extends* `string`
147+
148+
#### Parameters
149+
150+
##### field
151+
152+
`TField`
153+
154+
##### opts?
155+
156+
`UpdateMetaOptions`
157+
158+
#### Returns
159+
160+
`void`
161+
162+
***
163+
134164
### deleteField()
135165
136166
```ts
@@ -161,7 +191,7 @@ Defined in: [packages/form-core/src/FormApi.ts:1940](https://github.com/TanStack
161191
getAllErrors(): object
162192
```
163193
164-
Defined in: [packages/form-core/src/FormApi.ts:2211](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2211)
194+
Defined in: [packages/form-core/src/FormApi.ts:2237](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2237)
165195
166196
Returns form and field level errors
167197
@@ -433,7 +463,7 @@ parseValuesWithSchema(schema):
433463
}
434464
```
435465

436-
Defined in: [packages/form-core/src/FormApi.ts:2271](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2271)
466+
Defined in: [packages/form-core/src/FormApi.ts:2297](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2297)
437467

438468
Parses the form's values with a given standard schema and returns
439469
issues (if any). This method does NOT set any internal errors.
@@ -467,7 +497,7 @@ parseValuesWithSchemaAsync(schema): Promise<
467497
}>
468498
```
469499

470-
Defined in: [packages/form-core/src/FormApi.ts:2283](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2283)
500+
Defined in: [packages/form-core/src/FormApi.ts:2309](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2309)
471501

472502
Parses the form's values with a given standard schema and returns
473503
issues (if any). This method does NOT set any internal errors.
@@ -646,7 +676,7 @@ Optional options to control the reset behavior.
646676
resetField<TField>(field): void
647677
```
648678

649-
Defined in: [packages/form-core/src/FormApi.ts:2131](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2131)
679+
Defined in: [packages/form-core/src/FormApi.ts:2157](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2157)
650680

651681
Resets the field value and meta to default state
652682

@@ -698,7 +728,7 @@ resets every field's meta
698728
setErrorMap(errorMap): void
699729
```
700730

701-
Defined in: [packages/form-core/src/FormApi.ts:2149](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2149)
731+
Defined in: [packages/form-core/src/FormApi.ts:2175](https://github.com/TanStack/form/blob/main/packages/form-core/src/FormApi.ts#L2175)
702732

703733
Updates the form's errorMap
704734

0 commit comments

Comments
 (0)