Skip to content

Commit

Permalink
list: show nested sections
Browse files Browse the repository at this point in the history
* shows links to section if _index.md is present
* by this sub-sections can be distinguished properly
* more about this and way to implement: https://gohugo.io/content-management/organization/#index-pages-_indexmd
  • Loading branch information
adityatelange committed Oct 13, 2020
1 parent 0a0d756 commit 95e6bf1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/_default/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ <h1>{{ .Title }}</h1>
</header>
{{- end }}

{{- $pages := .RegularPages }}
{{- $pages := union .RegularPages .Sections }}

{{- if .IsHome }}
{{- $pages = where site.RegularPages "Type" "in" site.Params.mainSections }}
Expand Down

2 comments on commit 95e6bf1

@adityatelange
Copy link
Owner Author

@adityatelange adityatelange commented on 95e6bf1 Oct 13, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additions to be done:

  1. Sub-Sections are listed at last Irrespective of the date, they should be rearranged.
  2. Subsection cards show, time-to-read as 0, as there is no content in _index.md, that should be hidden.
  3. Sub-Sections aren't included in index.xml of parent's index.xml i.e. feeds won't catch up if posts is in subsection, although https://examplesite.com/index.xml has all the entries

@adityatelange
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.