| 2 | import { Action, ReactContext, Usable } from 'shared/ReactTypes'; |
| 3 | |
| 4 | export interface Dispatcher { |
| 5 | useState: <T>(initialState: (() => T) | T) => [T, Dispatch<T>]; |
| 6 | useEffect: (callback: () => void | void, deps: HookDeps | undefined) => void; |
| 7 | useTransition: () => [boolean, (callback: () => void) => void]; |
| 8 | useRef: <T>(initialValue: T) => { current: T }; |
| 9 | useContext: <T>(context: ReactContext<T>) => T; |
| 10 | use: <T>(usable: Usable<T>) => T; |
| 11 | useMemo: <T>(nextCreate: () => T, deps: HookDeps | undefined) => T; |
| 12 | useCallback: <T>(callback: T, deps: HookDeps | undefined) => T; |
| 13 | } |
| 14 | |
| 15 | export type Dispatch<State> = (action: Action<State>) => void; |
| 16 |
nothing calls this directly
no outgoing calls
no test coverage detected