/* * @Description: app moudle * @Author: ZY * @Date: 2020-12-23 10:25:37 * @LastEditors: ZY * @LastEditTime: 2021-01-05 15:39:49 */ import {CommitOptions, DispatchOptions, Module, Store as VuexStore} from 'vuex' // TODO: How to surpass cyclical dependency linting errors cleanly? import { state } from './state' import { mutations } from './mutations' import { actions } from './actions' import type { AppState } from './state' import getters from './getters' import {Mutations} from "./mutations"; import {Actions} from "./actions"; import {RootState} from "../../index"; export { AppState } export type AppStore = Omit, 'getters' | 'commit' | 'dispatch'> & { commit[1]>( key: K, payload: P, options?: CommitOptions ): ReturnType } & { dispatch( key: K, payload: Parameters[1], options?: DispatchOptions ): ReturnType }; export const store: Module = { state, mutations, actions, getters }