2
0

config.js 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. import { viteBundler } from '@vuepress/bundler-vite'
  2. import { defaultTheme } from '@vuepress/theme-default'
  3. import { defineUserConfig } from 'vuepress'
  4. export default defineUserConfig({
  5. title: 'DADK文档',
  6. description: 'DragonOS Application Development Kit',
  7. bundler: viteBundler(),
  8. base: process.env.NODE_ENV === 'production' ? '/p/dadk/' : '/',
  9. theme: defaultTheme(
  10. {
  11. repo: 'DragonOS-Community/DADK',
  12. repoLabel: 'GitHub',
  13. editLinks: true,
  14. // 默认为 "Edit this page"
  15. editLinkText: '帮助我们改善此页面!',
  16. smoothScroll: true,
  17. docsBranch: 'main',
  18. nextLinks: true,
  19. logo: 'https://static.dragonos.org.cn/casdoor/dragonos_en_pic.png',
  20. docsDir: 'docs',
  21. navbar: [
  22. {
  23. text: '首页',
  24. link: '/',
  25. },
  26. {
  27. text: '用户指南',
  28. link: '/user-manual/',
  29. },
  30. {
  31. text: '开发者指南',
  32. link: '/dev-guide/',
  33. },
  34. ],
  35. sidebar: {
  36. '/': 'heading',
  37. '/dev-guide/': [
  38. {
  39. text: '开发者指南',
  40. children: [
  41. '/dev-guide/README.md',
  42. '/dev-guide/how-to-write-docs.md',
  43. ],
  44. },
  45. ],
  46. '/user-manual/': [
  47. {
  48. text: '用户指南',
  49. children: [
  50. '/user-manual/quickstart.md',
  51. '/user-manual/profiling.md',
  52. ]
  53. }
  54. ]
  55. }
  56. }
  57. ),
  58. })