Skip to content

Commit

Permalink
fix: docs
Browse files Browse the repository at this point in the history
Signed-off-by: Neko Ayaka <[email protected]>
  • Loading branch information
nekomeowww committed Aug 1, 2024
1 parent 8db1432 commit eb795e5
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 23 deletions.
17 changes: 16 additions & 1 deletion docs/.vitepress/theme/index.mts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,21 @@ export default {
defaultToggle: true,
},
})
app.use(NolebaseGitChangelogPlugin)
app.use(NolebaseGitChangelogPlugin, {
locales: {
'en': {
gitChangelogMarkdownSectionTitles: {
changelog: 'Changelog',
contributors: 'Contributors',
},
},
'zh-CN': {
gitChangelogMarkdownSectionTitles: {
changelog: '页面历史',
contributors: '贡献者',
},
},
},
})
},
} satisfies Theme
29 changes: 7 additions & 22 deletions docs/vite.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -3,49 +3,34 @@ import { defineConfig } from 'vite'
import UnoCSS from 'unocss/vite'
import Inspect from 'vite-plugin-inspect'

import { GitChangelog,GitChangelogMarkdownSection } from '@nolebase/vitepress-plugin-git-changelog/vite'
import { GitChangelog, GitChangelogMarkdownSection } from '@nolebase/vitepress-plugin-git-changelog/vite'

export default defineConfig({
ssr: {
noExternal: [
// If there are other packages that need to be processed by Vite, you can add them here.
'@nolebase/vitepress-plugin-enhanced-readabilities',
'@nolebase/vitepress-plugin-highlight-targeted-heading',
'asciinema-player'
'@nolebase/ui-asciinema',
],
},
optimizeDeps: {
exclude: ['vitepress'],
exclude: [
'vitepress',
],
},
plugins: [
Inspect(),
// https://vitejs.dev/guide/api-plugin.html
GitChangelog({
repoURL: 'https://github.com/nekomeowww/ollama-operator',
rewritePaths: {
'docs/': ''
}
}),
GitChangelogMarkdownSection({
locales: {
'en': {
gitChangelogMarkdownSectionTitles: {
changelog: 'Changelog',
contributors: 'Contributors'
}
},
'zh-CN': {
gitChangelogMarkdownSectionTitles: {
changelog: '页面历史',
contributors: '贡献者'
}
}
},
excludes: [
join('pages', 'en', 'index.md'),
join('pages', 'zh-CN', 'index.md')
join('pages', 'zh-CN', 'index.md'),
],
}),
UnoCSS()
UnoCSS(),
],
})

0 comments on commit eb795e5

Please sign in to comment.