diff options
| author | Serghei Iakovlev <egrep@protonmail.ch> | 2022-05-08 18:47:25 +0200 |
|---|---|---|
| committer | Serghei Iakovlev <egrep@protonmail.ch> | 2022-05-08 18:47:25 +0200 |
| commit | b29419c9c72bbc2d605addabf0dfd84a7f41b88b (patch) | |
| tree | 4199578140684b30d7fb93e5c28b86db39442c83 /layouts/partials/post-meta/date.html | |
| parent | 40288d1362e1074c6e2c0d0d9de5a2d59bc86fb5 (diff) | |
| download | gohugo-theme-ed-b29419c9c72bbc2d605addabf0dfd84a7f41b88b.tar.gz | |
Provide ability to list posts on main page
Diffstat (limited to 'layouts/partials/post-meta/date.html')
| -rw-r--r-- | layouts/partials/post-meta/date.html | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/layouts/partials/post-meta/date.html b/layouts/partials/post-meta/date.html new file mode 100644 index 0000000..6afce4c --- /dev/null +++ b/layouts/partials/post-meta/date.html @@ -0,0 +1,11 @@ +{{- if not .Date.IsZero }} +<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}"> + {{- .Date.Format (site.Params.dateformat | default "January 02, 2006") -}} +</time> +{{- if ne .Date .Lastmod }} +<time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}"> + {{- /* TODO: Translate me */}} + Updated: {{- .Lastmod.Format (site.Params.dateformat | default "January 02, 2006") -}} +</time> +{{- end -}} +{{- end }} |
