Skip to content
masterclassBuddyTech Buzz5 fresh blogs · 5:00 AM IST

Conform · Module

intent.update

Conform's update intent changes a field, including nested or list fields, through an intent button. Pass the target field name and replacement value to form.update.getButtonProps.

How it works

The update intent changes a field or fieldset without a normal submit. Configure the button with the target field's metadata name and the replacement value; Conform uses field keys to remount inputs so their initial values reflect the update.

Syntax

form.update.getButtonProps({ name, value })

Parameters

NameTypeDescription
namestringField metadata name to update; the documented example passes fields.agenda.name.
valueunknownReplacement value for the selected field or fieldset.

Returns

The button-props helper returns props for a submit button that dispatches the update intent.

Key points

  • The update intent is a built-in control for changing a field's value without treating the action as an ordinary submit.
  • An update button can replace values for regular fields as well as nested or list fields.
  • Inputs need the metadata key so React can remount them after an update and display the new initial value.
  • Use dedicated insert, remove, or reorder intents for structural changes to field lists instead of using update.

Common mistakes

  • Provide the field metadata key to inputs when using update, so React can remount them with the updated initial value.

Example: Update a field with a button

import { useForm } from '@conform-to/react';

export function AgendaForm() {
  const [form, fields] = useForm({ id: 'agenda' });

  return (
    <form id={form.id} method="post">
      <input {...fields.agenda.title} />
      <button
        {...form.update.getButtonProps({
          name: fields.agenda.name,
          value: { title: 'My agenda' },
        })}
      >
        Update agenda
      </button>
    </form>
  );
}

The update intent button replaces the agenda field value with the supplied object.

When to use it

Apply a preset value

Replace a field or fieldset with a new object or scalar value.

Update structured fields

Refresh nested or list-field inputs after replacing their initial data.

Intent-driven controls

Change values through a button without a conventional form submission.

Interview questions

QHow do you update a field with Conform?

Use the update intent through form.update.getButtonProps(...), supplying the field metadata name and the replacement value. The button then performs the field update as a form intent rather than an ordinary submission.

Follow-up: How would you update the whole form? Omit name; the update dispatcher treats the missing name as a request to update the entire form.

QWhat does the update intent change?

The button is configured with the field name and a new value. For nested or list fields, the same update mechanism can target the corresponding field metadata.

Follow-up: What must inputs include for the UI to reflect the update? Their field metadata key, because Conform relies on it to trigger React remounting.

QHow does update relate to other intent controls?

Update is one of Conform's form-control intents, alongside reset and list operations such as insert, remove, and reorder. It is exposed through the form's update button helper.

Follow-up: When should a list be manipulated instead? Use insert, remove, or reorder when the operation changes list membership or ordering rather than replacing a field value.

  • reset intent
  • insert intent
  • remove intent
  • reorder intent
  • field metadata key
  • useForm

Source: Intent button. Checked 2026-10-15.