2024-01-01 19:39:04 -05:00
|
|
|
{{ if and (not .Date.IsZero) (not .Params.hideDate) (not .Site.Params.hideDate) }}
|
2022-05-08 18:02:35 -04:00
|
|
|
{{ $publishString := .Scratch.Get "beforeDateString" }}
|
|
|
|
{{ $singlePageDateFormat := .Site.Params.singlePageDateFormat | default "January 2, 2006"}}
|
|
|
|
{{ $pubdate := .Date.Format $singlePageDateFormat }}
|
|
|
|
|
2022-05-16 14:54:30 -04:00
|
|
|
<p class="date">
|
|
|
|
<i class="fas fa-calendar"></i>
|
|
|
|
{{ $publishString }}
|
|
|
|
<time class="dt-published" datetime='{{ .Date.Format "2006-01-02T15:04:05Z0700" }}'>{{ $pubdate }}</time>
|
|
|
|
</p>
|
2022-05-08 18:02:35 -04:00
|
|
|
|
|
|
|
{{- if and (not (.Scratch.Get "noDateUpdate")) .Lastmod }}
|
|
|
|
{{- $lastmod := .Lastmod.Format $singlePageDateFormat }}
|
|
|
|
{{- if ne $lastmod $pubdate }}
|
2022-05-16 14:54:30 -04:00
|
|
|
<p class="date-updated">
|
|
|
|
Updated on
|
|
|
|
<time class='dt-updated' datetime='{{ .Lastmod.Format "2006-01-02T15:04:05Z0700" }}'>{{ $lastmod }}</time>
|
|
|
|
</p>
|
2022-05-08 18:02:35 -04:00
|
|
|
{{- end }}
|
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|