diff --git a/packages/toolkits/pro/package.json b/packages/toolkits/pro/package.json index f2f15ca8..336681a3 100644 --- a/packages/toolkits/pro/package.json +++ b/packages/toolkits/pro/package.json @@ -1,6 +1,6 @@ { "name": "@opentiny/tiny-toolkit-pro", - "version": "1.0.20", + "version": "1.0.21", "description": "TinyPro 开箱即用的中后台前端/设计解决方案", "main": "dist/index.js", "typings": "dist/index.d.ts", diff --git a/packages/toolkits/pro/template/tinyvue/src/router/routes/index.ts b/packages/toolkits/pro/template/tinyvue/src/router/routes/index.ts index aa3c8ac8..ee0ca2cc 100644 --- a/packages/toolkits/pro/template/tinyvue/src/router/routes/index.ts +++ b/packages/toolkits/pro/template/tinyvue/src/router/routes/index.ts @@ -1,6 +1,6 @@ import type { RouteRecordRaw } from 'vue-router'; -const modules = import.meta.globEager('./modules/*.ts'); +const modules = import.meta.glob('./modules/*.ts', { eager: true }); const appRoutes: RouteRecordRaw[] = []; Object.keys(modules).forEach((key) => { diff --git a/packages/toolkits/pro/template/tinyvue/src/store/modules/app/index.ts b/packages/toolkits/pro/template/tinyvue/src/store/modules/app/index.ts index d1d3c0c2..7bb6bc7b 100644 --- a/packages/toolkits/pro/template/tinyvue/src/store/modules/app/index.ts +++ b/packages/toolkits/pro/template/tinyvue/src/store/modules/app/index.ts @@ -7,7 +7,7 @@ const useAppStore = defineStore('app', { getters: { appCurrentSetting(state: AppState): AppState { - return { ...state }; + return state; }, appDevice(state: AppState) { return state.device; diff --git a/packages/toolkits/pro/template/tinyvue/src/store/modules/user/index.ts b/packages/toolkits/pro/template/tinyvue/src/store/modules/user/index.ts index 998dedaf..09992554 100644 --- a/packages/toolkits/pro/template/tinyvue/src/store/modules/user/index.ts +++ b/packages/toolkits/pro/template/tinyvue/src/store/modules/user/index.ts @@ -37,7 +37,7 @@ const useUserStore = defineStore('user', { getters: { userInfo(state: UserState): UserState { - return { ...state }; + return state; }, },