1
0
mirror of https://github.com/alanorth/hugo-theme-bootstrap4-blog.git synced 2024-12-26 12:14:29 +01:00
Commit Graph

3 Commits

Author SHA1 Message Date
26e0a9a259
layouts/partials/recent.html: Only list "Regular" pages
This makes Hugo only list "Regular" pages in the sidebar. Otherwise
if you have very few posts, for example, you might see one entry in
the list called "Posts".

See: https://gohugo.io/functions/where/#mainsections
2019-05-26 10:28:31 +03:00
1655b876a8
Use .Site.Params.mainSections instead of hard coding "post" type
Hugo 0.32 or so added the quasi-magical .Site.Params.mainSections slice
that returns a range over the section that has the most number of pages.

This way we don't need to hard code the "post" type, and instead simply
use the pages that the user has created. Hugo's quickstart, for example,
recommends users create "posts", which currently doesn't work with this
theme!

Closes 
2018-03-09 17:50:03 +02:00
mathew
6d027091d4 Add caching of last N posts in sidebar to improve performance 2017-03-11 16:20:50 -06:00