重构:扩展默认主题配置,文章标题下新增显示作者名及发布时间信息

This commit is contained in:
2022-07-24 11:31:49 +08:00
parent 40676da91e
commit 43723a1de8
14 changed files with 104 additions and 19 deletions

View File

@@ -1,6 +1,7 @@
import { defineConfig } from 'vitepress'
import { metaData } from './config/constants'
import { head } from './config/head'
import { markdown } from './config/markdown'
import { themeConfig } from './config/theme'
export default defineConfig({
@@ -9,13 +10,7 @@ export default defineConfig({
description: metaData.description,
head, // <head>内标签配置
themeConfig, // 主题配置
lastUpdated: true, // 显示最后更新时间
// Markdown配置
markdown: {
theme: 'one-dark-pro', // Shiki主题, 所有主题参见: https://github.com/shikijs/shiki/blob/main/docs/themes.md
lineNumbers: true // 启用行号
}
markdown: markdown, // Markdown配置
themeConfig // 主题配置
})