chore: 容器框架升级,修复项目命令行异常问题
This commit is contained in:
8
apps/y-code-v1/src/router/guards.ts
Normal file
8
apps/y-code-v1/src/router/guards.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import type { NavigationGuardWithThis } from 'vue-router';
|
||||
|
||||
const titleGuard: NavigationGuardWithThis<undefined> = (to, from, next) => {
|
||||
next();
|
||||
document.title = to.meta.title ? `${to.meta.title} | 悦码` : '悦码';
|
||||
};
|
||||
|
||||
export { titleGuard };
|
||||
Reference in New Issue
Block a user