This is beta documentation for Stream Chat React SDK v14. For the latest stable version, see the latest version (v13) .

ChannelList Hooks

ChannelList uses a small internal hook set to query channels, recover from reconnects, and read channel membership state. These hooks are not the primary customization surface for channel-list behavior; prefer the ChannelList event handlers, query options, and WithComponents overrides first.

Best Practices

  • Prefer ChannelList props over reimplementing internal hook behavior.
  • Keep custom query logic close to usePaginatedChannels so pagination state stays consistent.
  • Use the membership-state hooks for read-only UI, not for mutating channel state directly.
  • Treat reconnect behavior as a reload concern and keep custom recovery handlers lightweight.
  • Avoid re-adding the removed standalone listener hooks; they are now internal to the list shape logic.

Hooks

HookDescription
useChannelMembersStateReads the current channel.state.members map and keeps it in sync with membership, ban, delete, and presence events. Use it when a custom channel-list row or header needs live member data from a specific channel.
useChannelMembershipStateReads the connected user’s channel.state.membership object and keeps it updated on membership changes. Use it when your UI needs the current user’s membership record for the active or previewed channel.
useConnectionRecoveredListenerRegisters a connection.recovered listener and runs a provided callback, which is how the default list triggers a reload when the SDK is not recovering channel state automatically.
usePaginatedChannelsQueries channels, manages channels and hasNextPage, and exposes loadNextPage() plus setChannels(). It is the default query/pagination model used by ChannelList, including support for a custom query function and active-channel initialization.

Current Customization Model

  • event-driven list behavior is owned by ChannelList
  • reconnect handling is available through useConnectionRecoveredListener
  • query and pagination behavior is available through usePaginatedChannels
  • membership-derived UI can use useChannelMembersState and useChannelMembershipState

If your app needs custom channel-row behavior, prefer WithComponents and ChannelListItemUI over rebuilding the deleted listener-hook layer.