Doc Categories Tags

:information_source: Summary Mixes topics with a tag into one category’s list, and gives topics listed in a doc index the docs sidebar
:eyeglasses: Preview See it in action here
:hammer_and_wrench: Repository GitHub - criptonautas/discourse-doc-categories-tags: Discourse theme component: lists topics with a given tag on one category page · GitHub
:question: Install Guide How to install a theme or theme component
:open_book: New to Discourse Themes? Beginner’s guide to using Discourse Themes

Install this theme component

Doc Categories builds documentation from one category, so docs filed elsewhere stay out of it. With this component, tag a topic anywhere and it shows up in your documentation category.

docs-categories-tags-screenshot.png

What it does

  • Mixes tagged topics into the category’s list, with the usual rows and the tab’s sort. Topics aren’t duplicated, and the category’s pinned topics stay pinned.
  • Gives the docs sidebar to topics an index links to, even when they’re filed in another category.
  • Hides the tag pill on that category’s list, where it only repeats what the page already is.

Three more rules are off by default: redirecting /tag/<tag> to the category, hiding #tag hashtags in posts, and hiding disabled rows in the composer’s tag search. The last two apply site-wide.

It doesn’t add topics to the index topic. It can be done with a workflow or maintained by manually edits.

Requirements

  • Discourse 2026.7.2 or later
  • Tagging enabled
  • Doc Categories, for the sidebar behavior

Settings

Setting Default
tag_name wiki Tag to mix in. Only the first is used.
target_category empty Category that gains those topics. Required for the merge.
redirect_tag_page false Send /tag/<tag> to the category
hide_tag_hashtags false Site-wide: #tag hashtags render nothing in posts
hide_disabled_tag_rows false Site-wide: hide disabled rows in the composer’s tag search

Known limits

  • The sidebar patches Doc Categories internals. If they change, the sidebar goes back to its default and a console warning names this component.
  • Doc Categories’ doc_categories_extraneous_items report may list index links to topics in other categories.
  • All tagged topics load up front, up to 20 pages, and merged rows appear a moment after the list.
  • The Top tab’s order is approximate and ignores the period.
  • The optional redirect is client side, so crawlers don’t follow it. A 301 at a proxy fixes that, as long as it leaves /tag/<tag>/l/<filter>.json alone.

Tested on our community from different browsers and clients with low traffic interaction. Suggestions, bug reports and PRs are welcome.

לייק 1

very nice, thank you for your contribution

לייק 1