* Add support for client-side search with Fuse.js. Implements #42. Based on https://gist.github.com/eddiewebb/735feb48f50f0ddd65ae5606a1cb41ae * Move search form code repeated in many places to one single template. * Add search box in home page. * Fix search UI + Some improvements Signed-off-by: hossainemruz <hossainemruz@gmail.com> * Remove search.md from exampleSite Signed-off-by: hossainemruz <hossainemruz@gmail.com> Co-authored-by: Emruz Hossain <hossainemruz@gmail.com>
5 lines
372 B
JSON
5 lines
372 B
JSON
{{- $.Scratch.Add "index" slice -}}
|
|
{{- range .Site.RegularPages -}}
|
|
{{- $.Scratch.Add "index" (dict "title" .Title "hero" (partial "helpers/get-hero.html" .) "date" (.Date.Format "January 2, 2006") "summary" .Summary "tags" .Params.tags "categories" .Params.categories "contents" .Plain "permalink" .Permalink) -}}
|
|
{{- end -}}
|
|
{{- $.Scratch.Get "index" | jsonify -}}
|