@microsoft/fast-element > BindingDirective

BindingDirective class

A directive that configures data binding to element content and attributes.

Signature:
export declare class BindingDirective extends Directive

Constructors

ConstructorModifiersDescription
(constructor)(binding)Creates an instance of BindingDirective.

Properties

PropertyModifiersTypeDescription
bindingBinding
createPlaceholder(index: number) => stringCreates a placeholder string based on the directive's index within the template.
targetNamestring | undefinedGets/sets the name of the attribute or property that this binding is targeting.

Methods

MethodModifiersDescription
createBehavior(target)Creates the runtime BindingBehavior instance based on the configuration information stored in the BindingDirective.
targetAtContent()Makes this binding target the content of an element rather than a particular attribute or property.