hugo-theme/layouts/search/search.json
2024-10-21 13:47:30 +02:00

9 lines
375 B
JSON

{{- $.Scratch.Add "index" slice -}}
{{- range .Site.Sites -}}
{{- $pages := where .RegularPages "Params.hidden" "!=" true -}}
{{- range $pages -}}
{{- $.Scratch.Add "index" (dict "title" .Title "tags" .Params.tags "categories" .Params.categories "content" .Plain "permalink" .Permalink) -}}
{{- end -}}
{{- end -}}
{{- $.Scratch.Get "index" | jsonify -}}