首页路径

reco_luan2023-02-20

介绍

某些场景下,文档的首页并不一定是文档根目录的 README.md 文件,这时我们可以在 Frontmatter 中设置 home: true 来置顶首页,并通过 themeConfig.home 来指定首页路径。

配置

# another-home-path.md
---
title: 指定首页
home: true
---
// .vuepress/config.ts

import { defineUserConfig } from 'vuepress'
import { recoTheme } from 'vuepress-theme-reco'

export default defineUserConfig({
  theme: recoTheme({
    home: '/another-home-path'
  })
})
最后更新时间 4/19/2024, 4:55:54 PM
ON THIS PAGE