1 | export interface Actions<T> {
|
2 | setLeft: () => void;
|
3 | setRight: () => void;
|
4 | set: (value: T) => void;
|
5 | toggle: () => void;
|
6 | }
|
7 | declare function useToggle<T = boolean>(): [boolean, Actions<T>];
|
8 | declare function useToggle<T>(defaultValue: T): [T, Actions<T>];
|
9 | declare function useToggle<T, U>(defaultValue: T, reverseValue: U): [T | U, Actions<T | U>];
|
10 | export default useToggle;
|