mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-06 09:26:44 +08:00
19 lines
353 B
JavaScript
19 lines
353 B
JavaScript
import { createRouter, createWebHashHistory } from 'vue-router';
|
|
import routesConfig from './config';
|
|
// console.log('routesConfig', routesConfig)
|
|
|
|
const routes = [
|
|
{
|
|
path: '/',
|
|
name: '首页',
|
|
redirect: routesConfig[0].path
|
|
},
|
|
...routesConfig
|
|
]
|
|
|
|
const router = createRouter({
|
|
history: createWebHashHistory(),
|
|
routes
|
|
})
|
|
|
|
export default router |