perf: 页面切换性能优化 (#600)

* perf: 页面切换性能优化

* fix: 修复刷新页面时`router.beforeEach`调用两次的问题
This commit is contained in:
xiaoming
2023-06-13 12:36:54 +08:00
committed by GitHub
parent aec2a35424
commit 5d86b714a4
9 changed files with 28 additions and 83 deletions

View File

@@ -21,10 +21,8 @@ const { t, route, locale, translationCh, translationEn } =
useTranslationLang(menuRef);
const {
device,
routers,
logout,
onPanel,
menuSelect,
resolvePath,
username,
userAvatar,
@@ -72,7 +70,6 @@ watch(
mode="horizontal"
class="horizontal-header-menu"
:default-active="defaultActive"
@select="indexPath => menuSelect(indexPath, routers)"
>
<el-menu-item
v-for="route in usePermissionStoreHook().wholeMenus"