fix: 修改路由模式

This commit is contained in:
YeMingfei666 2025-09-10 14:11:24 +08:00
parent 075c39d2b7
commit 0499e36a5b
1 changed files with 2 additions and 2 deletions

View File

@ -1,5 +1,5 @@
import type { App } from "vue";
import { createRouter, createWebHashHistory, type RouteRecordRaw } from "vue-router";
import { createRouter, createWebHashHistory, createWebHistory, type RouteRecordRaw } from "vue-router";
export const Layout = () => import("@/layout/index.vue");
@ -676,7 +676,7 @@ export const constantRoutes: RouteRecordRaw[] = [
*
*/
const router = createRouter({
history: createWebHashHistory(),
history: createWebHistory(),
routes: constantRoutes,
// 刷新时,滚动条位置还原
scrollBehavior: () => ({ left: 0, top: 0 }),