ChannelPreviewUnreadCount

Renders unread count inside ChannelList. This is the default component for the ChannelPreviewUnreadCount override.

Best Practices

  • Clamp counts with maxUnreadCount to avoid overflow.
  • Hide the badge when unread is zero.
  • Keep badge size consistent across the list.
  • Use channel-level unread counts for accuracy.
  • Avoid expensive formatting in render.

Props

Prop Description Type
channel Channel instance from the Stream Chat client. Channel
maxUnreadCount Max number shown in the unread badge. The value cannot exceed the backend limit of 255. Defaults to 255. number
unread Number of unread messages in the channel. number
Add Chat to my app: getstream.io/SKILL.md

The fastest way to build with Stream. Start a new project or improve an existing one. Full CLI and documentation integration out of the box.


Ask your agent:

/stream Build me a Social App with Feeds and Moderation.
/stream Any livestream calls running?
/stream Chat React Native v9: <Your Question>