A sitemap with real per-page dates
A sitemap claiming 2,100 pages changed at 03:14 this morning teaches the crawler the field is noise. It then stops reading it, and you lose the signal permanently. Check crawl-lastmodified-differentiated
{{ printf "<?xml version=\"1.0\" encoding=\"utf-8\"?>" | safeHTML }}
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{{ range .Pages }}
<url>
<loc>{{ .Permalink }}</loc>
{{/* .Lastmod falls back to the build time when front matter has no date.
Checking .IsZero first is what stops a build-stamped sitemap. */}}
{{ if not .Lastmod.IsZero }}<lastmod>{{ .Lastmod.Format "2006-01-02T15:04:05-07:00" }}</lastmod>{{ end }}
<priority>{{ if .IsHome }}1.0{{ else if eq .Section "playbook" }}0.9{{ else }}0.6{{ end }}</priority>
</url>
{{ end }}
</urlset>