123
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import {createRouter, createWebHashHistory, RouteRecordRaw} from 'vue-router';
|
||||
import {useUserStore} from "@/store/modules/user";
|
||||
import {domainStoreWidthOut} from "@/store/modules/domain";
|
||||
|
||||
export const constantRouter: Array<RouteRecordRaw> = [
|
||||
{
|
||||
@@ -235,6 +236,7 @@ const router = createRouter({
|
||||
|
||||
// @ts-ignore
|
||||
router.beforeEach((to, from, next) => {
|
||||
domainStoreWidthOut().refreshDomain();
|
||||
if (to.meta.title) { // 判断是否有标题
|
||||
document.title = to.meta.title as string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user