From ddcec0edf2a9b337ad91df00f1e4a1fac5af9666 Mon Sep 17 00:00:00 2001 From: lukasIO Date: Sun, 22 Dec 2024 10:31:30 +0100 Subject: [PATCH] add docs --- packages/livekit-rtc/src/data_streams/stream_reader.ts | 3 +++ packages/livekit-rtc/src/participant.ts | 1 + 2 files changed, 4 insertions(+) diff --git a/packages/livekit-rtc/src/data_streams/stream_reader.ts b/packages/livekit-rtc/src/data_streams/stream_reader.ts index 52b8670d..cb1b1c42 100644 --- a/packages/livekit-rtc/src/data_streams/stream_reader.ts +++ b/packages/livekit-rtc/src/data_streams/stream_reader.ts @@ -28,6 +28,9 @@ abstract class BaseStreamReader { abstract readAll(): Promise>; } +/** + * A class to read chunks from a ReadableStream and provide them in a structured format. + */ export class BinaryStreamReader extends BaseStreamReader { private chunksReceived: Set; diff --git a/packages/livekit-rtc/src/participant.ts b/packages/livekit-rtc/src/participant.ts index 623ca29a..cea9dc75 100644 --- a/packages/livekit-rtc/src/participant.ts +++ b/packages/livekit-rtc/src/participant.ts @@ -330,6 +330,7 @@ export class LocalParticipant extends Participant { return writer; } + /** Sends a file provided as PathLike to specified recipients */ async sendFile(path: PathLike, options?: FileStreamOptions) { const fileStats = await stat(path); const file = await open(path);