Files
Code-Create/src/routes.ts

70 lines
1.5 KiB
TypeScript
Raw Normal View History

2026-05-14 09:53:22 +08:00
import type { RouteRecordRaw } from 'vue-router'
2026-05-14 15:31:34 +08:00
import AboutView from './pages/about-us/index.vue'
2026-05-14 09:53:22 +08:00
import ContactView from './pages/ContactView.vue'
2026-05-14 17:15:49 +08:00
import HomeView from './pages/home/index.vue'
2026-05-14 09:53:22 +08:00
import ProductsView from './pages/ProductsView.vue'
2026-05-18 10:39:52 +08:00
import { LANGS } from './lang'
2026-05-14 09:53:22 +08:00
export const routes: RouteRecordRaw[] = [
2026-05-14 13:08:29 +08:00
{
2026-05-18 10:39:52 +08:00
path: `/:lang(${LANGS.join('|')})?`,
2026-05-14 13:08:29 +08:00
children: [
{
path: '',
component: HomeView,
},
{
2026-05-18 10:41:59 +08:00
path: 'about-us',
2026-05-18 10:41:18 +08:00
name: 'about-us',
2026-05-15 10:29:21 +08:00
component: AboutView
2026-05-14 13:08:29 +08:00
},
{
path: 'products',
name: 'products',
2026-05-15 10:29:21 +08:00
component: ProductsView
2026-05-14 13:08:29 +08:00
},
{
2026-05-18 10:41:59 +08:00
path: 'contact-us',
2026-05-14 13:08:29 +08:00
name: 'contact',
2026-05-15 10:29:21 +08:00
component: ContactView
2026-05-14 13:08:29 +08:00
},
2026-05-15 10:29:21 +08:00
{
path: 'aida',
name: 'Aida',
component: () => import('./pages/aida/index.vue')
2026-05-19 09:57:24 +08:00
},
{ path: 'events',
2026-05-19 09:57:24 +08:00
name: 'events',
component: () => import('./pages/events/index.vue')
},
2026-05-19 14:49:12 +08:00
{ path: 'user-stories',
name: 'user-stories',
component: () => import('./pages/user-stories/index.vue')
},
2026-05-18 15:22:08 +08:00
{
path: 'my-account',
name: 'MyAccount',
2026-05-18 16:46:55 +08:00
component: () => import('./pages/my-account/index.vue'),
children: [
{
path: '',
component: () => import('./pages/my-account/welcome.vue'),
},
{
path: 'orders',
component: () => import('./pages/my-account/orders.vue'),
},
2026-05-19 10:36:47 +08:00
{
path: 'subscriptions',
component: () => import('./pages/my-account/subscriptions.vue'),
},
2026-05-18 16:46:55 +08:00
{
path: ':pathMatch(.*)*',
component: () => import('./pages/my-account/welcome.vue'),
},
]
2026-05-18 15:22:08 +08:00
},
2026-05-15 10:29:21 +08:00
]
}
2026-05-14 09:53:22 +08:00
]
2026-05-15 17:31:43 +08:00