I’m tagging my pages in the front matter with things such as
tags: [ 'foo', 'bar' ]
To provide some documentation for my tags, I have pages:
-
content/tags/_index.md(an overview) content/tags/foo/_index.mdcontent/tags/bar/_index.md
(This is correct, right? content/tags/foo/_index.md rather than content/tags/foo.md?)
Now I’d like to apply a different layout for content/tags/_index.md and for content/tags/foo/_index.md. I’m reading https://gohugo.io/templates/lookup-order/ which I interpret to mean that I could define:
-
layouts/categories/tags.html.htmlforcontent/tags/_index.md, and -
layouts/categories/tag.htmlforcontent/tags/foo/_index.md
but not so.
What is the right way of doing this?