|
| 1 | +import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router'; |
| 2 | +import Home from '../views/Home.vue'; |
| 3 | + |
| 4 | +const routes: Array<RouteRecordRaw> = [ |
| 5 | + { |
| 6 | + path: '/', |
| 7 | + name: 'Home', |
| 8 | + component: Home, |
| 9 | + }, |
| 10 | + { |
| 11 | + path: '/general', |
| 12 | + name: 'General', |
| 13 | + meta: { |
| 14 | + title: 'General', |
| 15 | + }, |
| 16 | + component: () => |
| 17 | + import(/* webpackChunkName: "general" */ '../views/General.vue'), |
| 18 | + }, |
| 19 | + { |
| 20 | + path: '/basic', |
| 21 | + name: 'Basic', |
| 22 | + meta: { |
| 23 | + title: 'Basic', |
| 24 | + }, |
| 25 | + component: () => |
| 26 | + import(/* webpackChunkName: "basic" */ '../views/Basic.vue'), |
| 27 | + }, |
| 28 | + { |
| 29 | + path: '/text-fields', |
| 30 | + name: 'Text Fields', |
| 31 | + meta: { |
| 32 | + title: 'Text Fields', |
| 33 | + }, |
| 34 | + component: () => |
| 35 | + import(/* webpackChunkName: "text-fields" */ '../views/TextFields.vue'), |
| 36 | + }, |
| 37 | + { |
| 38 | + path: '/number-fields', |
| 39 | + name: 'Number Fields', |
| 40 | + meta: { |
| 41 | + title: 'Number Fields', |
| 42 | + }, |
| 43 | + component: () => |
| 44 | + import(/* webpackChunkName: "text-fields" */ '../views/NumberFields.vue'), |
| 45 | + }, |
| 46 | + { |
| 47 | + path: '/select-fields', |
| 48 | + name: 'Select Fields', |
| 49 | + meta: { |
| 50 | + title: 'Select Fields', |
| 51 | + }, |
| 52 | + component: () => |
| 53 | + import(/* webpackChunkName: "text-fields" */ '../views/SelectFields.vue'), |
| 54 | + }, |
| 55 | + { |
| 56 | + path: '/textarea-fields', |
| 57 | + name: 'TextArea Fields', |
| 58 | + meta: { |
| 59 | + title: 'TextArea Fields', |
| 60 | + }, |
| 61 | + component: () => |
| 62 | + import( |
| 63 | + /* webpackChunkName: "text-fields" */ '../views/TextAreaFields.vue' |
| 64 | + ), |
| 65 | + }, |
| 66 | + { |
| 67 | + path: '/checkbox-fields', |
| 68 | + name: 'Checkbox Fields', |
| 69 | + meta: { |
| 70 | + title: 'Checkbox Fields', |
| 71 | + }, |
| 72 | + component: () => |
| 73 | + import( |
| 74 | + /* webpackChunkName: "checkbox-fields" */ '../views/CheckboxFields.vue' |
| 75 | + ), |
| 76 | + }, |
| 77 | + { |
| 78 | + path: '/radio-fields', |
| 79 | + name: 'Radio Fields', |
| 80 | + meta: { |
| 81 | + title: 'Radio Fields', |
| 82 | + }, |
| 83 | + component: () => |
| 84 | + import(/* webpackChunkName: "radio-fields" */ '../views/RadioFields.vue'), |
| 85 | + }, |
| 86 | + { |
| 87 | + path: '/login', |
| 88 | + name: 'Login', |
| 89 | + meta: { |
| 90 | + title: 'Login', |
| 91 | + }, |
| 92 | + component: () => |
| 93 | + import(/* webpackChunkName: "campaigns" */ '../views/Login.vue'), |
| 94 | + }, |
| 95 | +]; |
| 96 | + |
| 97 | +const router = createRouter({ |
| 98 | + history: createWebHistory(process.env.BASE_URL), |
| 99 | + routes, |
| 100 | +}); |
| 101 | + |
| 102 | +export default router; |
0 commit comments