Skip to main content

Function: useSetFormField()

useSetFormField<Value>(conf): (value) => void

Defined in: lib/forms/fields.ts:169

Hook to set the value of a form field.

Type Parameters

Value

Value

Parameters

conf

FieldConfigAtom<Value>

The field configuration atom.

Returns

A function to set the value of the form field.

(value): void

A function for changing the value of a field. This will trigger a "change" validation event.

Parameters

value

The new value of the field

typeof RESET | Value | (prev) => Value

Returns

void