{{- $index := slice -}}
{{- range .Site.RegularPages -}}
    {{ if not (.Scratch.Get "params").search_hidden }}
        {{- $index = $index | append (dict "title" .Title "content" .Plain "permalink" .Permalink) -}}
    {{ end }}
{{- end -}}
{{- $index | jsonify -}}
