17 lines
646 B
HTML
17 lines
646 B
HTML
{{ $date := .Date | time.Format (site.Params.dateFormat | default "January 02, 2006") }}
|
|
{{ $lastmod := .Lastmod | time.Format (site.Params.dateFormat | default "January 02, 2006") }}
|
|
|
|
{{ i18n "published_on" }}
|
|
<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">
|
|
{{ $date }}
|
|
</time>
|
|
|
|
{{/* Check that lastmod exists and is greater than date
|
|
(i.e. the last modified date must be after the publish date) */}}
|
|
{{ if and (ne $lastmod $date) (gt .Lastmod .Date) }}
|
|
<span>•</span>
|
|
{{ i18n "updated_on" }}
|
|
<time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}">
|
|
{{ $lastmod }}
|
|
</time>
|
|
{{ end }}
|