feat: setting页面

This commit is contained in:
2026-04-22 10:30:55 +08:00
parent 1988d44c8d
commit 8a5a0ad3f5
6 changed files with 679 additions and 22 deletions

View File

@@ -7,32 +7,46 @@ import { createRouter, createWebHistory } from 'vue-router'
* 3. 路由的name默认是文件名,如果文件名与name不一致,通过defineOptions({ name: 'componentName' })来设置
*/
const router = createRouter({
history: createWebHistory('/'),
// history: createWebHistory(import.meta.env.VITE_APP_URL),
routes: [
{
path: '/',
name: 'home',
component: () => import('../views/home/index.vue'),
},
{
path: '/collectionStory',
name: 'collectionStory',
component: () => import('../views/collectionStory/index.vue'),
},
{
path: '/:pathMatch(.*)',
name: '404',
component: () => import('../views/404.vue'),
},
]
history: createWebHistory('/'),
// history: createWebHistory(import.meta.env.VITE_APP_URL),
routes: [
{
path: '/',
name: 'home',
component: () => import('../views/home/index.vue')
},
{
path: '/collectionStory',
name: 'collectionStory',
component: () => import('../views/collectionStory/index.vue')
// {
// path: '/',
// redirect: '/welcome'
// },
// {
// path: '/asistant',
// name: 'asistant',
// component: () => import('../views/asistant/index.vue'),
// meta: { cache: true, verify: () => VerifyIDs(2) }
},
{
path: '/settings',
name: 'settings',
component: () => import('@/views/setting/index.vue'),
meta: { cache: true }
},
{
path: '/:pathMatch(.*)',
name: '404',
component: () => import('../views/404.vue')
}
]
})
router.beforeEach((to, from, next) => {
next()
next()
})
router.afterEach(() => {
})
router.afterEach(() => {})
export default router