♻️(document): 调整文档结构

This commit is contained in:
就眠儀式
2022-06-25 20:10:12 +08:00
parent d18425cb2a
commit b86b7d308c
166 changed files with 528 additions and 60 deletions

View File

@@ -0,0 +1,16 @@
import {
createRouter as _createRouter,
createWebHistory,
Router,
} from "vue-router";
import zhCN from "./zh-CN";
const routes = [...zhCN];
export function createRouter(): Router {
const baseUrl = import.meta.env.BASE_URL;
return _createRouter({
history: createWebHistory(baseUrl),
routes: routes,
});
}

View File

@@ -0,0 +1,20 @@
import BaseLayout from "../layouts/Layout.vue";
const zhCN = [
{
path: "/",
redirect: "/zh-CN/index",
component: BaseLayout,
meta: { title: "首页" },
children: [
{
path: "/zh-CN/index",
component: () => import("../../docs/zh-CN/index.md"),
meta: { title: "指南" },
},
],
},
];
export default zhCN;