Interface WebComponent.CustomEventJs

All Superinterfaces:
Serializable
Enclosing class:
WebComponent<C extends Component>

@JsDefinition public static interface WebComponent.CustomEventJs extends Serializable
How an event of an exported web component is fired, as a JavaScript definition for Element.executeJs(Class).
Since:
25.4
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    fireEvent(String eventName, tools.jackson.databind.node.ObjectNode options)
    Fires an event on the host of the web component.
  • Method Details

    • fireEvent

      @JsExpression("this.dispatchEvent(new CustomEvent($0, $1));") void fireEvent(String eventName, tools.jackson.databind.node.ObjectNode options)
      Fires an event on the host of the web component.
      Parameters:
      eventName - the name of the event
      options - what the event is made of, including its detail