Skip to main content

provideFormNodePassThrough()

Marks a directive or host directive that consumes and delegates formNode, keeping the outer [formNode] binding passive while an inner control performs synchronization.

๐Ÿ“ Signatureโ€‹

provideFormNodePassThrough(): Provider;

๐Ÿงช Exampleโ€‹

@Directive({
selector: '[delegatesFormNode]',
providers: [provideFormNodePassThrough()],
})
export class DelegatesFormNode {
formNode = input.required<AnyNode>();
}

Use the delegated node on the inner control:

<input [formNode]="formNode()" />

Wrapper components with a public formNode input are detected automatically and do not need this provider. Directives and host directives require it because Angular does not expose equivalent public runtime input reflection for them.

Without the provider, the outer directive host may be treated as the control and fail because it is not a native control, recognized signal-control component, or ControlValueAccessor.

See [formNode] and Wrapper components.