MCPcopy Create free account
hub / github.com/react-hook-form/react-hook-form / _getFieldArray

Function _getFieldArray

src/logic/createFormControl.ts:678–687  ·  view source on GitHub ↗
(
    name: InternalFieldName,
  )

Source from the content-addressed store, hash-verified

676 );
677
678 const _getFieldArray = <TFieldArrayValues>(
679 name: InternalFieldName,
680 ): Partial<TFieldArrayValues>[] =>
681 compact(
682 get(
683 _state.mount ? _formValues : _defaultValues,
684 name,
685 _options.shouldUnregister ? get(_defaultValues, name, []) : [],
686 ),
687 );
688
689 const setFieldValue = (
690 name: InternalFieldName,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected