Search the Archives

Screenshot of site search menu, input containing the text "koji", with matching tags highlighted below, such as '#KojiBuildsCommunity"

New site feature: search!

Well, at least the interface for it is new anyways. Since this is a WordPress site, search has always been available, but I neglected to include an interface for it when I hastily published the site in 2020. And then… well let’s just say I thought I’d be working on the site more often than I was actually able to. Better late than never, though.

One relatively good consequence of launching search 2 years into posting on the site is that I’ve been diligent about tagging posts, and the search interface includes a list of tags based on your query that you can choose from to take you directly to the archive of posts that include that tag.

The list of matching tags was simpler to add than it looks thanks to Awesomplete, a JavaScript library developed by Lea Verou all the way back in 2015. Thanks Lea! Coupled with the WordPress REST API, it took me just one evening to make it happen. Don’t ask why it was this particular evening and not, say, an evening 2 years ago—it’s just how this works, ok?

Let me know if you find anything good!