From 408ce401cadce66e4de748dec48daf5e8af00477 Mon Sep 17 00:00:00 2001 From: YM <479443481@qq.com> Date: 星期三, 15 五月 2024 23:35:52 +0800 Subject: [PATCH] 1 --- src/router/index.ts | 13 +++++++------ 1 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/router/index.ts b/src/router/index.ts index af82e54..3a6e220 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -1,4 +1,4 @@ -import { createRouter, createWebHashHistory } from 'vue-router' +import { createRouter, createWebHashHistory, createWebHistory } from 'vue-router' import Layout from '@/layout/layout.vue' const Home = () => import('@/views/home.vue') const Login = () => import('@/views/login.vue') @@ -6,10 +6,6 @@ const router = createRouter({ history: createWebHashHistory(import.meta.env.BASE_URL), routes: [ - { - path: '/', - redirect: 'home' - }, { path: '/login', name: 'login', @@ -24,10 +20,15 @@ name: 'home', meta: { auth: true }, component: Home + }, + { + path: '/dictionary', + name: 'dictionary', + meta: { auth: true }, + component: () =>import('@/views/components/dictionary.vue') } ] } - ] }) -- Gitblit v1.9.1