diff --git a/types/kos-core/index.d.ts b/types/kos-core/index.d.ts index 20c4f25d20..b73f9d3980 100644 --- a/types/kos-core/index.d.ts +++ b/types/kos-core/index.d.ts @@ -20,7 +20,7 @@ interface WrapperConfig { interface Action { type: string; - payload?: Partial; + payload?: Partial & { [x: string]: any }; } export interface KosProps { @@ -40,7 +40,7 @@ export interface KosModel { [key: string]: (state: T, { payload }: { payload: T }) => void; }; asyncs: { - [key: string]: (dispatch: KosDispatch, getState: GetKosState, action: Action) => void; + [key: string]: (dispatch?: KosDispatch, getState?: GetKosState, action?: { payload: T }) => void; }; setup?: (dispatch: KosDispatch, getState: GetKosState) => void; getAsync?: (