mirror of
https://github.com/youzan/vant.git
synced 2025-10-16 08:00:34 +00:00
fix(cli): incorrect route redirect config
This commit is contained in:
@@ -49,13 +49,17 @@ function getRoutes() {
|
||||
routes.push({
|
||||
name: 'notFound',
|
||||
path: '/:path(.*)+',
|
||||
redirect: (route) => `/${getLangFromRoute(route)}/`,
|
||||
redirect: (route) => ({
|
||||
name: getLangFromRoute(route),
|
||||
}),
|
||||
});
|
||||
} else {
|
||||
routes.push({
|
||||
name: 'notFound',
|
||||
path: '/:path(.*)+',
|
||||
redirect: '/',
|
||||
redirect: {
|
||||
name: 'home',
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user