ReviewOS

also looking at this

stacks/bunpress

fix: preserve deployment paths in local search results

#91
Merged chris wants to merge codex/search-base-path into main
5 files +81 -23
docs/features/search.mdmodified+8-0
Changes to docs/features/search.md
@@ -362,6 +362,14 @@ generated pages. Skip it when you do not need search in a given build:
362362bunpress build --no-search-index
363363```
364364
365## Deployment under a path
366
367Local search results use the same deployment path as rendered pages. With
368`basePath: '/docs'`, a result for `guide.md` opens `/docs/guide`; section anchors
369and locale paths retain that prefix. When no explicit base path is set, the
370pathname of `sitemap.baseUrl` or `url` supplies it, matching the page renderer.
371Root-hosted sites retain their existing paths.
372
365373## Accessibility
366374
367375Search is accessible by default: