Sendbird Chat SDK for JavaScript.
OTHER License
Published by sendbird-sdk-deployment over 1 year ago
GroupChannelCollection
could not handle EVENT_MESSAGE_SENT
Published by sendbird-sdk-deployment over 1 year ago
fetch
polyfill with AbortController
supportMessageCollection
not carrying parentMessage
value when they shouldPublished by sendbird-sdk-deployment over 1 year ago
You can now control the size of your local cache. Starting from 64mb, decide how much you want to store (Default: 256mb).
Once the size limit is reached, the SDK will automatically remove messages and channels with pre-specified logic (clearOrder
) so that you don't have to actively manage it.
LocalCacheConfig
const localCacheConfig: LocalCacheConfig = new LocalCacheConfig({
maxSize: 256,
clearOrder: CachedDataClearOrder.MESSAGE_COLLECTION_ACCESSED_AT,
});
SendbirdErrorCode.DATABASE_ERROR
getCachedDataSize()
in SendBirdChatOpenChannelCreateParams.isEphemeral
disconnectWebsocket()
is calledMemoryStore
when SDK is running in a browser that does not support indexedDB
Published by liamcho over 1 year ago
Polls is now supported in both Open Channels and Group Channels!
Poll.serialize()
PollModule.buildPollFromSerializedData()
onPollUpdated
, onPollVoted
, and onPollDeleted
in OpenChannelHandlerParams
GroupChannel
to BaseChannel
:
updatePoll()
deletePoll()
closePoll()
addPollOption()
updatePollOption()
deletePollOption()
votePoll()
getPollChangeLogsSinceTimestamp()
getPollChangeLogsSinceToken()
createPollListQuery()
createPollVoterListQuery()
GroupChannelFilter
using nicknames (nicknameContainsFilter
, nicknameExactMatchFilter
, and nicknameExactMatchFilter
) includes current user's nickname when searching from locally cached group channelsBaseMessage.applyThreadInfoUpdateEvent()
always returning falseBaseChannel
’s createMessageMetaArrayKeys
, deleteMessageMetaArrayKeys
, addMessageMetaArrayValues
, and removeMessageMetaArrayValues
returning unexpected result when file message is givenPublished by danney-chun over 1 year ago
When you call sb.disconnect
, it disconnects the WebSocket and clears local cache. You can think of it as logging out.
In some cases, you need to only disconnect the WebSocket. You can now do it by calling sb.disconnectWebSocket
.
It only disconnects the WebSocket and preserves the local cache.
sb.disconnectWebSocket();
To connect again after disconnecting with disconnectWebSocket(),
use sb.connect().
const user = await sb.connect(userId: userId);
Added SendbirdChatParams.appStateToggleEnabled which can be used to optionally disable internal control of Websocket connection on document.visibilityState change
groupChannel.members
was not updated while disconnectedPublished by liamcho over 1 year ago
poll.votedOptionIds
is not updated upon calling poll.applyPollUpdateEvent(pollUpdateEvent)
MessageCollectionEventHandler.onMessagesDeleted
messages: BaseMessage[]
messageIds: number[]
onMessagesDeleted
callback now returns either unsent or sent messages through a new parameter messages: BaseMessage[]
, which you can use to remove pending messagesMessageRequestHandler.onPending
is called when pending message is marked for auto-resendMessageCollection.hasNext
remains true after MessageCollection.initialize()
is called with startingPoint
as nowMessageCollectionEventHandler
when handler has not been setMessageCollectionEventHandler.onMessagesUpdated
is called on update of GroupChannel
s getUnreadMemberCount
and getUndeliveredMemberCount
EVENT_MESSAGE_READ
and EVENT_MESSAGE_DELIVERED
in MessageEventSource
BaseMessageCreateParams
and BaseMessageUpdateParams
Published by liamcho over 1 year ago
Participant is a new interface for User who joined Open Channel. It's optimized for scalability and contains much lighter information about the User than a Member in Group Channel.
Now clients can implement Open Channels easier in SDK with more built-in capabilities. You can compare how Member, Participant, and User are different here
Participant
holds essential information about the participant like below. They contain their muted status (is_muted
) on top of basic User informationclass Participant extends User {
readonly isMuted: boolean;
}
ParticipantListQuery.next()
now returns Promise<Participant[]>
Promise<User[]>
, but the return value can be casted into Promise<Participant[]>
Published by liamcho over 1 year ago
SendbirdChatOptions.sessionTokenRefreshTimeout
. You can now set longer timeout value for session token expire. (Default: 60s, Maximum: 1800s). This means that Sendbird SDK will wait longer for your new session token, making it easier for you to reconnect to our service.Published by liamcho over 1 year ago
groupChannelHandler.onChannelChanged()
is not called on pin or unpin message eventparams
in getMessageChangeLogsSinceTimestamp()
, and getMessageChangeLogsSinceToken()
is now made optionalPublished by liamcho over 1 year ago
MessageCollection.hasPrevious
is false when there exists old messagesPublished by liamcho almost 2 years ago
onChannelsAdded
event is not fired upon creating a first channel in GroupChannelCollection
when localCacheEnabled
is set to falsePublished by danney-chun almost 2 years ago
MessageCollection
onMessagesUpdated event triggered for old messagesconnect
while offline did not reconnect
even when the app came onlinePublished by liamcho almost 2 years ago
MessageCollection
where old messages are being added to the view when app reconnectsGroupChannel.pinMessage()
and GroupChannel.unpinMessage()
GroupChannelHandler.onChannelChanged()
and GroupChannelHandler.onPinnedMessageUpdated()
events are not called when channel.lastPinnedMessage
is updatedPublished by chrisallo almost 2 years ago
GroupChannelCollection.dispose()
not to clear the event handlerMessageCollection.dispose()
not to clear the event handlerPublished by chrisallo almost 2 years ago
MessageCollection.dispose()
not to clear the event handlerPublished by liamcho almost 2 years ago
sb.connect()
right after sb.disconnect()
throws an error given the user had entered an open channelWebSocket
connection handlingPublished by liamcho almost 2 years ago
Pinned Message is released. You can now maintain a special set of messages (up to 10 per channel) that you want everyone in the channel to share. It can be anything from announcements, surveys, upcoming events, and any many more. Pin your messages and never miss them!
Stay tuned for updates as we are rolling out more exciting features and see below for exact specifications👇
UserMessageCreateParams.isPinnedMessage: boolean = false
FileMessageCreateParams.isPinnedMessage: boolean = false
GroupChannel.pinMessage(messageId: number): Promise<void>
GroupChannel.unpinMessage(messageId: number): Promise<void>
GroupChannel.lastPinnedMessage: BaseMessage = null
GroupChannel.pinnedMessageIds: number[] = []
Published by liamcho almost 2 years ago
MessageCollection
now loads unsent messages from cache before onCacheResult()
is calledPublished by liamcho almost 2 years ago
Changelog
SendableMessage
to BaseMessage
in some message updating methods in BaseChannel
and GroupChannel
SessionHandler
triggers onSessionTokenRequired
event even when authToken
is still validPublished by chrisallo almost 2 years ago