Skip to main content
cngx-src documentation

FieldSyncOptions

Interface

projects/forms/field/field-sync.ts

Import#

import { FieldSyncOptions } from '@cngx/forms/field'

Description#

Options for createFieldSync. Generic in V so the same factory covers scalar and array value shapes.

Index#

Instance Properties#

coerceFromField#function
Readonly

Normalise fieldRef.value() (unknown through CngxFieldRef) into V.

componentValue#WritableSignal
Readonly

Source of truth for the control's bound value (a model() signal).

shouldSkipFieldValue#function
ReadonlyOptional

Optional. Returns true when the raw field value is absent/invalid for a control that always asserts its own value (a numeric slider is never "empty"). When true, the field->control read is skipped (the control keeps its value) and the control->field write is forced (the control seeds the field on mount). Omit for controls where the field is the sole source of truth - the default sync reads and writes symmetrically.

toFieldValue#function
ReadonlyOptional

Transform applied before writing V back to the field. Default: identity.

valueEquals#function
Readonly

Truthy result suppresses both directions of sync (the cycle guard).