UNPKG

437 BTypeScriptView Raw
1import type { EventConsumer, EventEmitter } from './types';
2export declare type NavigationEventEmitter<T extends Record<string, any>> = EventEmitter<T> & {
3 create: (target: string) => EventConsumer<T>;
4};
5/**
6 * Hook to manage the event system used by the navigator to notify screens of various events.
7 */
8export default function useEventEmitter<T extends Record<string, any>>(listen?: (e: any) => void): NavigationEventEmitter<T>;