import { Dispatch, SetStateAction } from 'react'; declare type SetStateFn = Dispatch>; declare type SafeSetState = [T | undefined, SetStateFn]; export declare function useSafeState(initialState?: T | (() => T | undefined)): SafeSetState; export declare const useSafeStateWithReducer: (initialValue: any) => any[]; export declare const useSafeStateWithReducerGeneric: (initialValue: T) => (T | ((args: T) => void))[]; export default useSafeState;