Functionfrom

Create an event from external event source. The init() function will be called immediately. The notify() function is used to emit data to event listeners.

  • Type Parameters

    • T = void

    Parameters

    • init: ((notify: ((data: T) => void)) => void | (() => void))
        • (notify): void | (() => void)
        • Parameters

          • notify: ((data: T) => void)
              • (data): void
              • Parameters

                • data: T

                Returns void

          Returns void | (() => void)

    Returns AddEventListener<T>

MMNEPVFCICPMFPCPTTAAATR