Skip to content

Replace Algolia search with Pagefind - #963

Draft
mtthwcmpbll wants to merge 1 commit into
mainfrom
feat/move-search-to-pagefind
Draft

Replace Algolia search with Pagefind#963
mtthwcmpbll wants to merge 1 commit into
mainfrom
feat/move-search-to-pagefind

Conversation

@mtthwcmpbll

Copy link
Copy Markdown
Contributor

Swaps the search engine from Algolia to Pagefind, which indexes the rendered HTML at build time and runs entirely in the browser — no search service, API key, or crawler. The modal keeps DocSearch's markup, class names, and stylesheet (vendored from @docsearch/css@4.6.3), so the UI, keyboard shortcuts, facet tabs, and recent/favourite searches are unchanged; @docusaurus/theme-search-algolia, @docsearch/react, algoliasearch, and search-insights are all gone, along with the theme's /search page, which is reimplemented in src/pages/search.tsx.

Recipe results now show the recipe ID instead of the generated excerpt, since recipes share display names across languages (three unrelated recipes are all called "Module has dependency") and their excerpts are identical boilerplate. Option names in OptionsTable are weighted in the index, so searching an option surfaces the recipes that actually take it — previously the top hit for methodPattern didn't declare it at all; now all of the top 10 do.

Indexing runs in postBuild for yarn build, and in the sharded CI build it stands down per-shard and runs against the merged output in the combine job. yarn start serves the last build's index, and reports clearly when there isn't one.

Two notes for reviewers: the "Powered by Algolia" footer logo is necessarily gone (keyboard hints pinned in place with a CSS override), and Algolia search analytics go away with it. The vendored stylesheet is pinned first in customCss — order is load-bearing, since DocSearch's .DocSearch-Button { all: unset } would otherwise wipe out custom.css's Morpheus restyle.

Verified: full build (8,635 pages indexed), tsc, validate:css, and knip clean, plus 21 new tests covering the Pagefind adapter and modal. The one failing test (filterUtils) fails on main too.

…s, and ensure that recipe options are searchable
@mtthwcmpbll
mtthwcmpbll marked this pull request as draft August 20, 2026 20:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant