import { AppState } from './state'; const getters = { getContextPath(state: AppState) {// 次方法是直接返回user这个数据 return state.contextPath; }, getModuleCode(state: AppState) {// 次方法是直接返回user这个数据 return state.moduleCode; }, keepAliveComponentsName(state: AppState) {// 次方法是直接返回user这个数据 return state.keepAliveComponentsName; }, getAppModules(state: AppState) {// 次方法是直接返回user这个数据 return state.appModules; }, getOption(state: AppState) {// 次方法是直接返回user这个数据 return state.options; }, token(state: AppState) {// 次方法是直接返回user这个数据 return state.token; }, loginInfo(state: AppState) {// 次方法是直接返回user这个数据 return state.loginInfo; }, isRelogin(state: AppState) {// 次方法是直接返回user这个数据 return state.isRelogin; } } export default getters;