Hacker News new | ask | show | jobs
by seriocomic 2106 days ago
Search and comments are the casualties of static-sites - unless you bow and crumble to the use of something 3rd party (Disqus or Google Site Search to name some poor examples)
4 comments

Can't you point algolia at a static site and get decent search or have I misunderstood?
You can check out Lunr. The Jekyll theme Minimal Mistakes has that as a search option and builds a JSON index file.

The demo site uses Algolia though https://mmistakes.github.io/minimal-mistakes/

Hugo provides a Json output that can be used by a js script to provide simple search. I guess the same is possible for other systems.

Comments, contact forms and other features that "creates" content are more difficult.

staticman[0] for comments is a neat solution that avoids those surveillance companies. it can use heroku hobby tier for processing and github as the content backend for a free, hosted comments solution for static sites (fully acknowledging that heroku and github are both owned by other surveillers).

[0]: https://github.com/eduardoboucas/staticman

Comments are not as important as search, I guess. If the site has tons of pages, not having search might be annoying to the user