Chat UIKit React v3
Chat UIKit React
Chat UIKit
React
Version 3

withSendbird()

Copy link

We strongly recommend you to use the hook pattern from useSendbirdStateContext and React function components instead of withSendbird().

The withSendbird() component is an HOC that helps you exchange data between the Chat SDK and the UIKit modules such as Channel, ChannelList, and ChannelSettings. You can also access data stored in the SendbirdProvider state using withSendbird(). These data are used to implement chat features and customize the UI of the modules.

Note : The Chat SDK can be accessed through state.stores.sdkStore.sdk or sendbirdSelectors.getSdk().

const CustomReactComponentWithSendbirdConsumer = withSendbird(CustomReactComponent, mapStateToProps);