Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/netzo/deps/react-hook-form.ts>UseFieldArrayAppend

Full-stack Deno framework for building business web apps like internal tools, dashboards, admin panels and automated workflows.
Go to Latest
type alias UseFieldArrayAppend
import { type UseFieldArrayAppend } from "https://deno.land/x/netzo@0.5.70/deps/react-hook-form.ts";

Append field/fields to the end of your fields and focus. The input value will be registered during this action.

Examples

Example 1

<button type="button" onClick={() => append({ name: "data" })}>Append</button>
<button type="button" onClick={() => append({ name: "data" }, { shouldFocus: false })}>Append</button>
<button
  type="button"
  onClick={() => append([{ name: "data" }, { name: "data" }])}
>
  Append
</button>

Type Parameters

TFieldValues extends FieldValues
optional
TFieldArrayName extends FieldArrayPath<TFieldValues> = FieldArrayPath<TFieldValues>