Skip to content

ui/build/collection-form/collection-form-values

ui/build/collection-form/collection-form-values

Functions

pickWritableFormValues()

function pickWritableFormValues(fields, values): Record<string, unknown>;

Defined in: apps/website/.api-docs-entry/ui/build/collection-form/collection-form-values.d.ts:10

Keeps only values the collection form is allowed to send back to a mutation.

An edit form starts from a complete hydrated row so it can render field values and framework metadata. The mutation boundary is deliberately narrower: Bolt-managed columns and generated authored columns are read context, never write input. Picking through the catalog here also keeps an undeclared key from a custom form composition from becoming an accidental graph mutation.

Parameters

Parameter Type
fields readonly CollectionField<string>[]
values Readonly<Record<string, unknown>>

Returns

Record<string, unknown>