commit 68d67007ba8adc8458312ccb561387a4063f466d
parent 0bca7c902197354b2f6178e7a271de7a7e5ca10f
Author: Oscar Benedito <oscar@oscarbenedito.com>
Date:   Thu,  3 Sep 2020 14:24:41 +0200

Fix datetime attributes parsing

Diffstat:
Mlayouts/_default/list.html | 2+-
Mlayouts/_default/single.html | 2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/layouts/_default/list.html b/layouts/_default/list.html @@ -22,7 +22,7 @@ <header> <h2 class="p-name"><a class="u-url" href="{{ .RelPermalink }}">{{ .Title }}</a></h2> <div class="metadata"> - {{ partial "categories.html" . }} &middot; <a href="{{ .RelPermalink }}"><data class="dt-published" datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 2, 2006" }}</data></a> &middot; {{ partial "read-time.html" . }} + {{ partial "categories.html" . }} &middot; <a href="{{ .RelPermalink }}"><time class="dt-published" datetime="{{ .Date.Format "2006-01-02T15:04:05-07:00" }}">{{ .Date.Format "January 2, 2006" }}</time></a> &middot; {{ partial "read-time.html" . }} <div> </header> <section class="content"> diff --git a/layouts/_default/single.html b/layouts/_default/single.html @@ -3,7 +3,7 @@ <article class="h-entry"> <header> <h1 class="p-name">{{ .Title }}</h1> - <div class="metadata">{{ partial "categories.html" . }} &middot; <a class="u-url" href="{{ .RelPermalink }}"><data class="dt-published" datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 2, 2006" }}</data></a>{{ if ne .Lastmod .Date }} (last modified on <data class="dt-updated" datetime="{{ .Lastmod.Format "2006-01-02" }}">{{ .Lastmod.Format "January 2, 2006" }}</data>){{ end }} + <div class="metadata">{{ partial "categories.html" . }} &middot; <a class="u-url" href="{{ .RelPermalink }}"><time class="dt-published" datetime="{{ .Date.Format "2006-01-02T15:04:05-07:00" }}">{{ .Date.Format "January 2, 2006" }}</time></a>{{ if ne .Lastmod .Date }} (last modified on <time class="dt-updated" datetime="{{ .Lastmod.Format "2006-01-02T15:04:05-07:00" }}">{{ .Lastmod.Format "January 2, 2006" }}</time>){{ end }} </div> </header> <div class="content e-content">{{ .Content }}</div>