Finally getting round to adding search to my blog, thanks to @zachleat's <pagefind-search> web component (https://www.zachleat.com/web/pagefind-search/). I've still got to sort out some of the styling, but the actual searching-for-text bit works.
It's my first time using a web component, and it was super easy once I figured out adding the JS to my build process