source: imaps-frontend/node_modules/react-use/esm/misc/hookState.d.ts

main
Last change on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago

Update repo after prototype presentation

  • Property mode set to 100644
File size: 696 bytes
Line 
1export declare type IHookStateInitialSetter<S> = () => S;
2export declare type IHookStateInitAction<S> = S | IHookStateInitialSetter<S>;
3export declare type IHookStateSetter<S> = ((prevState: S) => S) | (() => S);
4export declare type IHookStateSetAction<S> = S | IHookStateSetter<S>;
5export declare type IHookStateResolvable<S> = S | IHookStateInitialSetter<S> | IHookStateSetter<S>;
6export declare function resolveHookState<S>(nextState: IHookStateInitAction<S>): S;
7export declare function resolveHookState<S, C extends S>(nextState: IHookStateSetAction<S>, currentState?: C): S;
8export declare function resolveHookState<S, C extends S>(nextState: IHookStateResolvable<S>, currentState?: C): S;
Note: See TracBrowser for help on using the repository browser.