From 82b611ce9b9ee9aec96ef945da785e9ef6b5e602 Mon Sep 17 00:00:00 2001 From: litian <2804272236@qq.com> Date: 星期三, 15 五月 2024 20:10:23 +0800 Subject: [PATCH] 1 --- src/router/index.ts | 11 ++++++++--- 1 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/router/index.ts b/src/router/index.ts index af82e54..9664723 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -1,10 +1,10 @@ -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') const router = createRouter({ - history: createWebHashHistory(import.meta.env.BASE_URL), + history: createWebHistory(import.meta.env.BASE_URL), routes: [ { path: '/', @@ -24,10 +24,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