CloudCannon / pagefind

Static low-bandwidth search at scale
https://pagefind.app
MIT License
3.24k stars 99 forks source link

Use ellipsis for excerpts in default UI #531

Open skrysmanski opened 6 months ago

skrysmanski commented 6 months ago

I was wondering if it was possible to show ellipsis (i.e. ...) in the default UI for the excerpts - like how it shows up on Google.

At the moment, I'm getting this:

no-ellipsis

And I'm looking for this:

with-ellipsis

bglw commented 6 months ago

This would be a useful setting! I can add this when I'm next in the area, but in the meantime you could achieve this using the processResult hook of the Default UI. The excerpt key can be modified to change that text 🙂