Nested sections in Hugo: Demo


#1

See: http://hugotest.bep.is/

I’m close to wrapping this up; there are some minor issues left, but it is working. The plan is to get this released in Hugo 0.22 next Monday, i.e. one week from today.

NOTE: Please do not fill this thread with questions and “It would be nice if …”, but if you see something obviously wrong, then shout.


#2

Looks GREAT. Thank you!


#3

In the demo there is a “site tree view” partial:

I’m pretty happy with the simplicity of the new sections API. Also, note that the .Home.Site.Sections will get a shortcut in .Site.Sections in Hugo 23 (will have to get people over to the new API before we can reuse it).


#4

How do we list the pages for a given section now ? I used to iterate over .Site.Sections.mysectionname, but now on the SiteInfo object, the Sections is a method that returns Pages.

Now sure what’s the best way to migrate my previous behavior. To be clear, on the home page, I want to show cards for each page in a given section.

thanks!