Skip to content

Commit 85ab558

Browse files
authored
fix: export SessionHandler through UIKit (#283)
SessionHandler cannot be used by importing directly via `@sendbird/chat`
1 parent d65d16f commit 85ab558

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

exports.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ export default {
1616
'handlers/GroupChannelHandler': 'src/lib/handlers/GroupChannelHandler.ts',
1717
'handlers/OpenChannelHandler': 'src/lib/handlers/OpenChannelHandler.ts',
1818
'handlers/UserEventHandler': 'src/lib/handlers/UserEventHandler.ts',
19+
'handlers/SessionHandler': 'src/lib/handlers/SessionHandler.ts',
1920

2021
// ChannelList
2122
ChannelList: 'src/smart-components/ChannelList/index.tsx',

scripts/index_d_ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -870,6 +870,10 @@ declare module '@sendbird/uikit-react/handlers/ConnectionHandler' {
870870
import { ConnectionHandler } from '@sendbird/chat';
871871
export default ConnectionHandler;
872872
}
873+
declare module '@sendbird/uikit-react/handlers/SessionHandler' {
874+
import { SessionHandler } from '@sendbird/chat';
875+
export default SessionHandler;
876+
}
873877
declare module '@sendbird/uikit-react/handlers/GroupChannelHandler' {
874878
import { GroupChannelHandler } from '@sendbird/chat/groupChannel';
875879
export default GroupChannelHandler;

src/lib/handlers/SessionHandler.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/**
2+
* Returns the instance of SessionHandler
3+
*/
4+
import { SessionHandler } from "@sendbird/chat";
5+
6+
export default SessionHandler;

0 commit comments

Comments
 (0)