# 카테고리 숨김 테마 컴포넌트

**URL:** https://meta.discourse.org/t/category-hider-theme-component/181299
**Category:** Theme component
**Created:** [2월 27, 2021, 5:58오전 UTC](https://meta.discourse.org/t/category-hider-theme-component/181299 "2021-02-27T05:58:56Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![jrgong](https://avatars.discourse-cdn.com/v4/letter/j/c57346/32.png) [@jrgong](https://meta.discourse.org/u/jrgong)
#### Post date: [7월 23, 2021, 4:57오후 UTC](https://meta.discourse.org/t/category-hider-theme-component/181299/5 "2021-07-23T16:57:47Z")

</div>

케이건, 안녕?

이 컴포넌트는 우리가 미래에 필요로 할 것 같은 모습 그대로야. 우리의 사용 사례는 매우 구체적이며, 특정 상위 카테고리에서 하위 카테고리를 숨기는 것을 원해.

여기 있는 코드 스니펫과 결합하면 우리가 찾고 있는 것을 정확히 달성할 수 있을 것 같아:

> [@토픽 목록에서 하위 카테고리를 숨기되, 해당 카테고리의 토픽은 숨기지 않는 방법?](https://meta.discourse.org/t/hide-subcategories-without-hiding-their-topics-in-topic-list/195502/18):
>
> Yeah, there was an issue with how the category was set that I missed locally. I edited the snippet above, and it should work now. The snippet above allows you to set the categories you want this to work on. If you want it to work on all categories, you’d use something like this. \<script type="text/discourse-plugin" version="0.8"\> const { on } = require("discourse-common/utils/decorators"); const useParentCategory = function () { const parentCategory = this.attrs.topic.category.parentC…

---

_[View the full topic](https://meta.discourse.org/t/category-hider-theme-component/181299)._
