Options
All
  • Public
  • Public/Protected
  • All
Menu

Class EventTarget

Base class for objects that dispatches events.

Hierarchy

Index

Constructors

constructor

Methods

addEventListener

  • addEventListener(type: string, listener: Function): EventTarget

dispatchEvent

hasAnyEventListener

  • hasAnyEventListener(type: string): boolean
  • Check if any event listener of the given type is added

    Parameters

    • type: string

    Returns boolean

hasEventListener

  • hasEventListener(type: string, listener: Function): boolean
  • Check if an event listener is added

    Parameters

    • type: string
    • listener: Function

    Returns boolean

removeEventListener

  • removeEventListener(type: string, listener: Function): EventTarget