Skip to content

Commit

Permalink
perf: hide search api props md
Browse files Browse the repository at this point in the history
  • Loading branch information
lisonge committed Apr 13, 2024
1 parent 610ac52 commit 1a734e1
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,19 @@ export default defineConfig({
},
search: {
provider: 'local',
options: {
_render(src, env, md) {
const html = md.render(src, env);
if (env.frontmatter?.search === false) return '';
if (
env.relativePath.startsWith('api/interfaces/') &&
env.relativePath.endsWith('Props.md')
) {
return '';
}
return html;
},
},
},
socialLinks: [{ icon: 'github', link: 'https://github.com/gkd-kit' }],
footer: {
Expand Down

0 comments on commit 1a734e1

Please sign in to comment.