Search on a site with no server

How search works on a statically exported site, and why the cost is worth paying.

toolingperformance

A statically exported site has no server to query, so search can't be a request to an application backend the way it usually is. The alternative is to precompute an index at build time and ship it to the browser, which is what this site does.

The tradeoff is bandwidth: the browser downloads the whole index before it can answer the first query. For a tech notes library, that's the right tradeoff — notes are precisely the content found by search rather than by browsing, so search earns its cost here in a way it might not on a larger corpus.