Custom element property definition.

This is a parameter to @DomProperty decorator applied to component property.

Type Parameters

  • T extends object = any

    A type of component.

Hierarchy

  • DomPropertyDef

Properties

configurable?: boolean

Whether the declared property should be configurable.

Defaults to configurable attribute of decorated property.

enumerable?: boolean

Whether the declared property should be enumerable.

Defaults to enumerable attribute of decorated property.

propertyKey?: PropertyKey

Property key.

Decorated property key is used by default.

updateState?: boolean | StatePath | DomPropertyUpdateReceiver<T>

Whether to update the component state after this property changed.

Can be one of:

  • false to not update the component state,
  • true (the default value) to update the component state with changed property key,
  • a state value key to update, or
  • an DOM property update receiver function with custom state update logic.
writable?: boolean

Whether the declared property should accept new values.

The property can not be writable if the decorated property is not writable.

Defaults to writable attribute of decorated property.

Generated using TypeDoc