mirror of
https://github.com/theNewDynamic/gohugo-theme-ananke.git
synced 2025-06-08 09:12:47 +00:00
Add ".Site.Params.Dateformat" configuration
Use ".Site.Params.Dateformat" for formatiing of dates. If it isn’t configured stay with the default ""January 2, 2006".
This commit is contained in:
parent
8c1280c2a3
commit
6b71b94a49
@ -19,7 +19,7 @@
|
||||
</h1>
|
||||
{{/* Hugo uses Go's date formatting is set by example. Here are two formats */}}
|
||||
<time class="f6 mv4 dib tracked" datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">
|
||||
{{- .Date.Format "January 2, 2006" -}}
|
||||
{{- default "January 2, 2006" .Site.Params.Dateformat | .Date.Format -}}
|
||||
</time>
|
||||
</header>
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user