UNPKG

use-app-events

Version:

Create, trigger and listen for custom events in vanilla JavaScript and React.

11 lines (10 loc) 412 B
type Options = { /** When false, `notifyEventListeners` will not broadcast events to other browsing contexts (tabs, windows) by default. */ broadcast: boolean; /** When true, the debug mode will be enabled globally, resulting in additional logs. */ debug: boolean; /** Reset options to their initial state. */ reset: () => void; }; declare const options: Options; export default options;