“Overwriting default landing page for Hugo taxonomies”. What do I mean by that? By default, Hugo will create a home page or a landing page for your taxonomies. /tags/
or /categories
are good examples. If you don’t have any specific templates for tags /layouts/tags/list.html
Hugo will use the default one /layouts/_default/list.html
and create an index.html for tags implicitly. If you want to change the front-matter for that index page or add some content to it for some reason, you need to create the index page yourself. Now, Hugo will use the file you’ve created.
In my site, I wanted to change “tags” to “archives”. To do that, I’ve created a new file /content/tags/_index.md
and changed set a new title
property in it’s front-matter. By the way, it doesn’t have to be a taxonomy page. This is also valid for any other section under /contents
. We don’t have to create an index page for each section but we can create one if we want to overwrite defaults and add something special for that section. For more see related docs Taxonomies, Content Organization