Taxonomy.html inside a custom taxonomy folder ignored

Hi there,

I seem to have the same problem as reported here Problem with taxonomy.html inside a custom folder, however there is no solution there.

The problem is as follows:

I have configured the following in order to have a custom taxonomy called “integrations tags”:

# config.toml
[taxonomies]
  integration_tags = "integrations/tags"

And I have the following content and templates:

The expected behavior would be to have as output integratrions/tags/<tag-name>/index.html rendered from layouts/integrations/taxonomy.html.

But the actual behavior is that it’s rendered from layouts/_default/taxonomy.html.

This issue is reproducible in this repo GitHub - messutied/taxonomy-issue.

Any advice on how to do this properly would be greatly appreciated.

This works:

layouts/
├── _default/
│   ├── baseof.html
│   ├── home.html
│   ├── list.html
│   └── single.html
└── integrations/
    └── tags/
        └── term.html

This is a little surprising, but I’m not sure that nested taxonomies were ever an intentional feature.

That does work! Thank you so much :slight_smile:

Is there a less hackie way to achieve this? The reason we went this way is cos we need different set of tags for blog posts and integrations, and this is the only way to achieve this I could find.

I cannot think of another way to handle this, and you are certainly not alone in taking this approach. Even though nested taxonomies are not documented, I suspect (but cannot guarantee) that this is future proof.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.