import { RouteRecordRaw } from 'vue-router'; const routes: RouteRecordRaw[] = [ { path: '/', component: () => import('src/layouts/MainLayout.vue'), // If we get so big we need lazy loading, we can use imports again // component: () => import('layouts/MainLayout.vue'), children: [ { path: '', // If we get so big we need lazy loading, we can use imports again // component: () => import('pages/IndexPage.vue'), component: () => import('src/pages/IndexPage.vue'), name: 'index', }, { path: '/boat', component: () => import('src/pages/BoatPage.vue'), name: 'boat', }, { path: '/schedule', component: () => import('pages/schedule/SchedulePageView.vue'), name: 'schedule', children: [ { path: '', component: () => import('pages/schedule/ScheduleIndexPage.vue'), name: 'schedule-index', }, { path: 'book', component: () => import('src/pages/schedule/BoatReservationPage.vue'), name: 'reserve-boat', }, { path: 'view', component: () => import('src/pages/schedule/BoatScheduleView.vue'), name: 'boat-schedule', }, ], }, { path: '/certification', component: () => import('src/pages/CertificationPage.vue'), name: 'certification', }, { path: '/task', name: 'task', children: [ { path: '', component: () => import('src/pages/task/TaskPage.vue'), name: 'task-index', }, { path: '/:id/edit', component: () => import('pages/task/TaskEditPage.vue'), name: 'edit-task', }, ], }, { path: '/checklist', component: () => import('pages/ChecklistPage.vue'), name: 'checklist', }, { path: '/profile', component: () => import('src/pages/ProfilePage.vue'), name: 'profile', }, { path: '/reference', component: () => import('src/pages/reference/ReferencePage.vue'), name: 'reference', children: [ { path: '', component: () => import('src/pages/reference/ReferenceIndexPage.vue'), name: 'reference-index', }, { path: '/reference/:id/view', component: () => import('src/pages/reference/ReferenceItemPage.vue'), }, ], }, ], }, { path: '/admin', component: () => import('layouts/AdminLayout.vue'), children: [ { path: '/user', component: () => import('pages/admin/UserAdminPage.vue'), name: 'useradmin', }, { path: '/boat', component: () => import('pages/admin/BoatAdminPage.vue'), name: 'boatadmin', }, ], }, { path: '/login', component: () => import('pages/LoginPage.vue'), name: 'login', meta: { publicRoute: true, }, }, { path: '/terms-of-service', component: () => import('pages/TermsOfServicePage.vue'), name: 'tospage', meta: { publicRoute: true, }, }, { path: '/privacy-policy', component: () => import('pages/PrivacyPolicyPage.vue'), name: 'privacy-policy', meta: { publicRoute: true, }, }, // { // path: '/register', // component: () => import('pages/RegisterPage.vue'), // name: 'register' // meta: { // accountRoute: true, // } // }, // Always leave this as last one, // but you can also remove it { path: '/:catchAll(.*)*', component: () => import('pages/ErrorNotFound.vue'), }, ]; export default routes;