1 | import type { DependencyList, ReanimatedEvent } from './commonTypes';
|
2 | interface GeneralHandler<Event extends object, Context extends Record<string, unknown>> {
|
3 | (event: ReanimatedEvent<Event>, context: Context): void;
|
4 | }
|
5 | type GeneralHandlers<Event extends object, Context extends Record<string, unknown>> = Record<string, GeneralHandler<Event, Context> | undefined>;
|
6 | export interface UseHandlerContext<Context extends Record<string, unknown>> {
|
7 | context: Context;
|
8 | doDependenciesDiffer: boolean;
|
9 | useWeb: boolean;
|
10 | }
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 | export declare function useHandler<Event extends object, Context extends Record<string, unknown>>(handlers: GeneralHandlers<Event, Context>, dependencies?: DependencyList): UseHandlerContext<Context>;
|
22 | export {};
|
23 |
|
\ | No newline at end of file |