{{- $count := site.Params.home.recentPostsCount | default 5 -}} {{- $all := where site.RegularPages "Type" "post" -}} {{- $posts := first $count $all -}} {{- with $posts -}}

{{ i18n "recentPosts" | default "Recent Posts" }}

{{- if gt (len $all) $count }}

{{ i18n "viewAll" | default "View all" }} →

{{- end }}
{{- end -}}