Exclude category posts from displaying on home page?

Hi,

Our daily update posts here -

Are overwhelming the other types of posts. Is it possible to exclude posts from the daily-network-updates category from displaying on the home page?

Thank you!

Head over to the category settings for that category and tick this box under the settings tab

3 Likes

We’ve generally moved away from recommending that setting, in favor of forcefully setting the “mute this category” preference for all (or some) users on your site.

Perhaps that setting should be removed @sam to indicate just how much we no longer think people should be using it.

3 Likes

I support removing this setting, but I worry that we are giving admins no easy avenue to set all users to mute specific categories historically. This makes it particularly difficult when you add a category and want it default muted.

How do you feel about providing admins with some UX here? In particular:

  • Admin adds a category to default_categories_muted (same for watched etc)
  • We detect … oh something changed…
    • Would you like all existing users to have “category X” muted?
    • Would you like to remove the category mute from N users?

I like this cause this provide a very clean way for admins to deal with this problem and it has happened countless times now on meta. With this in place I would love to nuke that category setting.

5 Likes

Yes totally that’s what I’m getting at. We get lots of requests for this, we even do it internally… so I fully support it.

2 Likes

Thanks for the replies. Why is the recommendation so strongly against using the existing option?

Ideally, I’d like to display, say, the most recent X updates from that category. The updates in question are daily updates. So I’d like users to see that these updates exist, yet prevent them from crowding out the updates from other channels.

@vinothkannans can you take this?

Whenever you change any of these settings we need to pop up a modal:

Would you like to apply this change historically? This will change preferences for 1234 existing users.

[Yes], [No, only apply change going forward]

There are edge cases so let me cover them.

  • Default categories watching changes from “cat1, cat2” → “cat1, cat3”

Historic change to apply:

All old users should STOP watching cat2 and START watching cat3. cat1 is untouched.

  • Removal is easy, it can be done blindly.

  • Adding new cat3 is a bit tricky, you only add it to users that are not tracking,muting,watching first post on this category already.

Once this is done you can remove the “category excluded from home page” category setting.

4 Likes

PR created

https://github.com/discourse/discourse/pull/8180

2 Likes

Can you share some screenshots of the workflow?


In above screenshot, the total user count (30) is fetched from the about model (about.json URL). Now I’m trying to include it in the site settings page model itself.

3 Likes

This looks great, I think it is more correct for this to be fetched on demand, no need to tax the page with extra load for the rare case we are adding a default.

I think the only change here is the Yes should be primary blue.

@codinghorror you happy with the copy?

5 Likes

The PR is now merged.

5 Likes

This topic was automatically closed after 34 hours. New replies are no longer allowed.