【发布时间】:2019-07-11 08:33:47
【问题描述】:
我想将我的 vue 路由从 /dashboards/dashboard 更改为 /dashboard。如何使用此代码实现这些
import Layout2 from '@/layout/Layout2'
export default [
{
path: '/dashboards',
component: Layout2,
children: [
{
path: 'dashboard',
name: 'dashboard',
component: () => import('@/components/dashboards/Dashboard')
}
]
}
]
我已尝试放置这些代码,但如果组件已添加,我该如何添加 layout2?
export default [
{
path: '/dashboard',
name: 'dashboard',
component: () => import('@/components/dashboards/Dashboard')
}
]
【问题讨论】:
标签: vue.js vue-router