You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
801 B
31 lines
801 B
import {createRouter, createWebHashHistory} from 'vue-router'; |
|
import Layout from '@/layout/index.vue' |
|
|
|
const routes = [ |
|
{ |
|
path: '/', |
|
name: 'Home', |
|
component: Layout, |
|
children: [ |
|
{ |
|
path: '/', |
|
name: 'hello', |
|
component: () => import('@/components/HelloWorld.vue') |
|
}, |
|
{ |
|
path: 'update', |
|
name: 'Update', |
|
component: () => import('@/views/update/index.vue') |
|
}, |
|
{ |
|
path: 'mock', |
|
name: 'Mock', |
|
component: () => import('@/views/mock/index.vue') |
|
} |
|
] |
|
} |
|
] |
|
|
|
const router = createRouter({history: createWebHashHistory(), routes}) |
|
|
|
export default router
|
|
|