11 lines
440 B
JSON
11 lines
440 B
JSON
|
{{- $.Scratch.Add "pagesIndex" slice -}}
|
||
|
{{- range $index, $page := .Site.Pages -}}
|
||
|
|
||
|
{{- if in (slice "category" ) $page.Type -}}
|
||
|
{{- if gt (len $page.Content) 0 -}}
|
||
|
{{- $pageData := (dict "title" $page.Title "href" $page.Permalink "categories" (delimit $page.Params.tags " ; ") "content" $page.Plain ) -}} {{- $.Scratch.Add "pagesIndex" $pageData -}}
|
||
|
{{- end -}}
|
||
|
{{- end -}}
|
||
|
{{- end -}}
|
||
|
{{- $.Scratch.Get "pagesIndex" | jsonify -}}
|