tangjunhao 1 주 전
부모
커밋
0ccce1c98a
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/router/index.js

+ 1 - 1
src/router/index.js

@@ -63,7 +63,7 @@ router.beforeEach((to, from, next) => {
     next({ name: 'login' });
   }
   else {
-    document.title = to.name || '默认标题';
+    document.title = to.meta.title || '默认标题';
     next();
   }
 });