Skip to content

Commit

Permalink
chore: add docs for prefetchIceCandidates option
Browse files Browse the repository at this point in the history
  • Loading branch information
farhat-ha committed Nov 14, 2024
1 parent aa9aac7 commit e68ad99
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions packages/js/src/TelnyxRTC.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,18 @@ export class TelnyxRTC extends TelnyxRTCClient {
* preferred_codecs: [PCMACodec],
* });
* ```
*
* ### ICE Candidate Prefetching
*
* ICE candidate prefetching can be enabled by passing `prefetchIceCandidates` to the `newCall` method.
* example:
* ```js
* client.newCall({
* destinationNumber: 'xxx',
* prefetchIceCandidates: true,
* });
* ```
*
*/
newCall(options: ICallOptions) {
return super.newCall(options);
Expand Down
2 changes: 1 addition & 1 deletion packages/js/src/utils/interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ export interface ICallOptions {
preferred_codecs?: RTCRtpCodecCapability[];

/**
* ICE Candidate Prefetching.
* Enable or disable ICE Candidate Prefetching.
*/
prefetchIceCandidates?: boolean;
}
Expand Down

0 comments on commit e68ad99

Please sign in to comment.