Skip to content

Commit c377cdc

Browse files
author
Saffo, David
committed
feat: add local search provider to VitePress config and remove benchmark example
1 parent f8fdd25 commit c377cdc

2 files changed

Lines changed: 11 additions & 49 deletions

File tree

docs/.vitepress/config.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,17 @@ export default defineConfig({
1414
editLink: {
1515
pattern: 'https://github.com/jpmorganchase/anu/tree/main/docs/:path'
1616
},
17+
search: {
18+
provider: 'local',
19+
options: {
20+
async _render(src, env, md) {
21+
const html = await md.renderAsync(src, env)
22+
if (env.frontmatter?.search === false) return ''
23+
if (env.relativePath.startsWith('anu-tutorial')) return ''
24+
return html
25+
}
26+
}
27+
},
1728
// https://vitepress.dev/reference/default-theme-config
1829
nav: [
1930
{ text: 'Docs', link: '/guide/' },

docs/examples/benchmark.md

Lines changed: 0 additions & 49 deletions
This file was deleted.

0 commit comments

Comments
 (0)