Skip to content

Commit 7f1c1bf

Browse files
Fix useDataChannel's send return type (#1080)
Co-authored-by: lukasIO <[email protected]>
1 parent a58b063 commit 7f1c1bf

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/short-dingos-jump.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@livekit/components-react": patch
3+
---
4+
5+
Fix useDataChannel's send return type

packages/react/src/hooks/useDataChannel.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { useObservableState } from './internal';
77

88
type UseDataChannelReturnType<T extends string | undefined = undefined> = {
99
isSending: boolean;
10-
send: (payload: Uint8Array, options: DataPublishOptions) => void;
10+
send: (payload: Uint8Array, options: DataPublishOptions) => Promise<void>;
1111
message: ReceivedDataMessage<T> | undefined;
1212
};
1313

0 commit comments

Comments
 (0)