acording to hope theme move search plugin config to theme config

This commit is contained in:
mahula 2024-01-25 19:52:34 +01:00
parent 4cb48ca98a
commit bd63322058
2 changed files with 15 additions and 16 deletions

View File

@ -1,21 +1,6 @@
import { searchProPlugin } from 'vuepress-plugin-search-pro'
import { redirectPlugin } from 'vuepress-plugin-redirect'
export default [
searchProPlugin({
indexContent: true,
autoSuggestions: true,
customFields: [
{
getter: (page) => page.frontmatter.category,
formatter: "Category: $content",
},
{
getter: (page) => page.frontmatter.tag,
formatter: "Tag: $content",
},
],
}),
redirectPlugin({
autoLocale: true,
})

View File

@ -98,6 +98,20 @@ export default hopeTheme({
sub: true,
sup: true,
vPre: true,
}
},
searchPro: {
indexContent: true,
autoSuggestions: true,
customFields: [
{
getter: (page) => page.frontmatter.category,
formatter: "Category: $content",
},
{
getter: (page) => page.frontmatter.tag,
formatter: "Tag: $content",
},
],
},
}
})