diff --git a/src/layouts/index.vue b/src/layouts/index.vue index 7b8b46c..98240ae 100644 --- a/src/layouts/index.vue +++ b/src/layouts/index.vue @@ -1,3 +1,3 @@ diff --git a/src/router/index.js b/src/router/index.js index f1228b3..772e805 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -1,5 +1,5 @@ import { createRouter, createWebHistory } from 'vue-router'; -// import Layout from '@/layouts/index.vue'; +import Layout from '@/layouts/index.vue'; import demoRouters from './modules/demo'; @@ -16,21 +16,21 @@ export const constantRoutes = [ // component: () => import('@/views/error/403.vue'), // hidden: true, // }, - // { - // path: '/', - // name: 'layout', - // component: Layout, - // redirect: '/home', - // meta: { title: '首页', icon: 'House' }, - // children: [ - // { - // path: '/home', - // component: () => import('@/views/home/index.vue'), - // name: 'home', - // meta: { title: '首页', icon: 'House' }, - // }, - // ], - // }, + { + path: '/', + name: 'layout', + component: Layout, + redirect: '/home', + meta: { title: '首页', icon: 'House' }, + children: [ + { + path: '/home', + component: () => import('@/views/home/index.vue'), + name: 'home', + meta: { title: '首页', icon: 'House' }, + }, + ], + }, ...demoRouters, ];