diff --git a/layouts/partials/blog/archive.html b/layouts/partials/blog/archive.html index fc61331..21e1a4a 100644 --- a/layouts/partials/blog/archive.html +++ b/layouts/partials/blog/archive.html @@ -1,6 +1,11 @@
{{ $prev := now.Format "2006"}} -

{{ $prev }}

+ {{ range first 1 .Pages.ByPublishDate.Reverse }} + {{if .Date}} + {{if eq $prev (.Date.Format "2006")}}

{{ $prev }}

{{end}} + {{end}} + {{end}} + {{range .Pages.ByPublishDate.Reverse}} {{if .Date}} {{$curr := .Date.Format "2006"}} @@ -16,4 +21,4 @@ {{ $prev = $curr}} {{end}} {{end}} -
+ \ No newline at end of file