Show Views instead of Replies

Hey guys, I would like to know if anyone has ever tried to show Views instead of the number of replies in the homepage.

I was able to hide the number of replies using CSS, but I’m having a hard time trying to show the number of Views in that place.

Any ideas? :slight_smile:

Thanks!

1 Like

I’m looking for this very feature. Have you found any solution to this? @Tiago_Amaral

Any updates @Discourse?

2 Likes

i may take a stab at this in next few days if i have time. i am working on a theme component that does something similar.

3 Likes

I went ahead and added a plugin outlet to make it extra easy:

If you add something like this to the Head section of a theme component, you’ll see it adds the views. You can add additional HTML if needed and style to taste from there :slight_smile:

<script type="text/x-handlebars" data-template-name="/connectors/above-latest-topic-list-item-post-count/views-count">
  {{topic.views}} views
</script>
2 Likes

oh nice. thank you. @tshenry :slight_smile:

1 Like

ok so i put this functionality into a theme component that has settings for controlling all three stats in the topic list of the main category page - total number of views, replies count, and time since last activity.

2 Likes