2
0
mirror of https://github.com/tusen-ai/naive-ui.git synced 2025-03-25 14:10:50 +08:00

fix: site vue-router warning

This commit is contained in:
07akioni 2020-12-16 11:17:56 +08:00
parent 024dd95ca5
commit 35d56075eb

@ -326,15 +326,17 @@ export const childRoutes = withPrefix('/:lang/:theme/doc', [
export const routes = [
{
name: 'site',
path: '/:lang/:theme',
component: () => import('../SiteProvider.vue'),
children: [
{
name: 'home',
path: '/:lang/:theme',
component: () => import('../documentation/landing/index.vue'),
name: 'home'
component: () => import('../documentation/landing/index.vue')
},
{
name: 'doc',
path: '/:lang/:theme/doc',
component: () => import('../Documentation.vue'),
children: childRoutes
@ -344,6 +346,12 @@ export const routes = [
{
name: 'not-found',
path: '/:pathMatch(.*)*',
redirect: '/zh-CN/os-theme'
redirect: {
name: 'home',
params: {
lang: 'zh-CN',
theme: 'os-theme'
}
}
}
]