Files
Mainpage/src/router/index.js

13 lines
304 B
JavaScript
Raw Normal View History

2025-03-01 21:30:49 +08:00
import { createRouter, createWebHistory } from 'vue-router'
2025-03-02 22:42:09 +08:00
import Home from '@/views/Home.vue' // 确保路径正确
2025-03-01 21:30:49 +08:00
const routes = [
2025-03-02 22:42:09 +08:00
{ path: '/', component: Home } // 确保根路径指向 Home 组件
2025-03-01 21:30:49 +08:00
]
const router = createRouter({
history: createWebHistory(),
routes
})
export default router