• Registers a callback function to be executed when the specified event occurs.

    Parameters

    • eventName: string

      The name of the event.

    • callback: Function

      The callback function to be executed. It takes no parameters.

    Returns Function

    • A function that, when called, will unregister the callback from the event.

Generated using TypeDoc