Sendbird UIKit for React provides various handlers such as channel event handlers and session handlers to manage activities and events that occur in the client app. See the guides below on how to install and use them.
Channel event handlers
Due to a version update from v3 to v4 in the Chat SDK, UIKit implemented custom channel event handlers that you can import instead of calling the channel handler from
sdkInstance. See the following codes on how to add the UIKit channel event handlers.
If a user is authenticated with a session token, the Chat SDK connects the user to the Sendbird server and can send data requests to it for ten minutes as long as the session token hasn't expired or hasn't been revoked. Upon the user's session expiration, the Chat SDK will refresh the session internally. However, if the session token has expired or has been revoked, the Chat SDK can't do so. In that case, the client app needs to implement a session handler to refresh the token and pass it back to the SDK so that it can refresh the session again. Refer to the code below on how to use the session handler in UIKit.