interface ReduxAction { type: string; } interface ReduxDispatch { (action: any): unknown; } interface GetState { (): unknown; } interface Thunk { (dispatch: ReduxDispatch, getState: GetState): any; } /** * For functions return its return type otherwise return void. * * Different from the core ReturnType which can oly be called for * functions. */ declare type FunctionReturnValue = T extends (...args: any[]) => infer R ? R : void; declare class SimpleStore { private _reduxDispatch; getState: GetState; constructor(dispatch: ReduxDispatch, getState: GetState); dispatch(action: T): FunctionReturnValue; } export declare function makeThunkCreator(mapStore: (store: SimpleStore) => MappedStore): (thunk: (...args: ThunkArgs) => (arg: MappedStore) => ThunkReturn) => (...args: ThunkArgs) => (reduxDispatch: ReduxDispatch, getState: GetState) => ThunkReturn; export {};