Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "lib/decorators"

Index

Type aliases

Variables

Functions

Type aliases

Constructor

Constructor: object

Type declaration

Variables

Const query

query: (Anonymous function) = _query((target: NodeSelector, selector: string) =>target.querySelector(selector))

A property decorator that converts a class property into a getter that executes a querySelector on the element's renderRoot.

Const queryAll

queryAll: (Anonymous function) = _query((target: NodeSelector, selector: string) =>target.querySelectorAll(selector))

A property decorator that converts a class property into a getter that executes a querySelectorAll on the element's renderRoot.

Functions

Const customElement

  • customElement(tagName: string): (Anonymous function)
  • Class decorator factory that defines the decorated class as a custom element.

    Parameters

    • tagName: string

      the name of the custom element to define

      In TypeScript, the tagName passed to customElement should be a key of the HTMLElementTagNameMap interface. To add your element to the interface, declare the interface in this module:

      @customElement('my-element')
      export class MyElement extends LitElement {}
      
      declare global {
        interface HTMLElementTagNameMap {
          'my-element': MyElement;
        }
      }

    Returns (Anonymous function)

Const eventOptions

  • eventOptions(options: AddEventListenerOptions): (Anonymous function)

Const property

  • A property decorator which creates a LitElement property which reflects a corresponding attribute value. A PropertyDeclaration may optionally be supplied to configure property features.

    Parameters

    Returns (Anonymous function)

Generated using TypeDoc