UNPKG

@modular-forms/react

Version:

The modular and type-safe form library for React

11 lines (10 loc) 518 B
import type { FieldValues, ResponseData, FieldArrayPath, FormStore, Maybe } from '../types'; /** * Returns a list with the names of all field arrays. * * @param form The form of the field arrays. * @param shouldValid Whether to be valid. * * @returns All field array names of the form. */ export declare function getFieldArrayNames<TFieldValues extends FieldValues, TResponseData extends ResponseData>(form: FormStore<TFieldValues, TResponseData>, shouldValid?: Maybe<boolean>): FieldArrayPath<TFieldValues>[];