StaticSearch v0.6.0 update
462 words, 3-minute read

StaticSearch v0.6.0 was released on . There should be no breaking changes but there are a few new features and results ordering may change.
Improved results ordering #
The latest update:
orders results from highest to lowest relevancy as before.
If those values match, it orders results from highest to lowest
foundvalue (a number between0and1that indicates the proportion of search words found in a page).If those values match, it orders results from newest to oldest date.
Highlight search words #
Setting a highlight attribute on the web component or bind module scrolls to and highlights the first matching search terms on a results page.
This uses text fragment links which can have issues:
searching for “highlight” will return pages containing “highlighted” and “highlighter”, but they are not highlighted.
A highlighted word could appear outside your main content, such as in a menu.
Selected search text #
When using the <static-search> web component, activating search now selects the current search term as well as focusing the field. This allows quicker searches for a new term.
Additional language support #
StaticSearch removes commonly-used stop words considered insignificant to the meaning of text – such as “and”, “the”, and “but” in English. This can produce better results and v0.6.0 now supports stop words in:
- Afrikaans (
af) - Croatian (
hr) - Czech (
cs) - Danish (
da) - Dutch (
nl) - English (
en) - Estonian (
et) - Finnish (
fi) - French (
fr) - German (
de) - Hungarian (
hu) - Irish (
ga) - Italian (
it) - Latvian (
lv) - Lithuanian (
lt) - Malay (
ms) - Norwegian (
no) - Polish (
pl) - Portuguese (
pt) - Romanian (
ro) - Slovak (
sk) - Somali (
so) - Spanish (
es) - Swahili (
sw) - Swedish (
sv) - Turkish (
tr) - Zulu (
zu)
Smaller payload #
Thanks to an esbuild update, the minified JavaScript has reduced by a couple of kilobytes to less than 11Kb – despite having more code!
Get started #
The StaticSearch documentation provides a quick start guide, and details about the indexer, web component, bind module, and JavaScript API.
StaticSearch works well with Publican sites. The Publican documentation provides a quick start guide, a detailed set-up guide, API references, and common recipes you can use and adapt for your own projects.