update jsonfeed for notes

This commit is contained in:
Phil 2025-01-08 15:54:46 -07:00
parent 3fb8d959d5
commit 38263a5906

View File

@ -5,13 +5,13 @@
"feed_url": "{{ .Permalink }}", "feed_url": "{{ .Permalink }}",
"description": "A feed of my notes from {{ .Site.Title }}", "description": "A feed of my notes from {{ .Site.Title }}",
"items": [ "items": [
{{- range .Pages.ByDate.Reverse -}} {{- range $index, $page := .Pages.ByDate.Reverse -}}
{ {
"id": "{{ .Permalink }}", "id": "{{ $page.Permalink }}",
"url": "{{ .Permalink }}", "url": "{{ $page.Permalink }}",
"content_text": {{ .Plain | jsonify }}, "content_text": {{ $page.Plain | jsonify }},
"date_published": "{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}" "date_published": "{{ $page.Date.Format "2006-01-02T15:04:05Z07:00" }}"
}{{ if not (last .Pages.ByDate.Reverse .) }},{{ end }} }{{ if lt $index (sub (len .Pages) 1) }},{{ end }}
{{- end }} {{- end }}
] ]
} }