mirror of
https://github.com/xtr-dev/rondevu-client.git
synced 2025-12-10 10:53:24 +00:00
Add WebRTC polyfill support for Node.js environments
Added optional polyfill parameters to RondevuOptions to support Node.js: - RTCPeerConnection: Custom peer connection implementation - RTCSessionDescription: Custom session description implementation - RTCIceCandidate: Custom ICE candidate implementation This allows users to plug in wrtc or node-webrtc packages for full WebRTC support in Node.js environments. Updated documentation with usage examples and environment compatibility matrix. Version bumped to 0.7.4 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -27,7 +27,7 @@ export abstract class PeerState {
|
||||
async handleIceCandidate(candidate: any): Promise<void> {
|
||||
// ICE candidates can arrive in multiple states, so default is to add them
|
||||
if (this.peer.pc.remoteDescription) {
|
||||
await this.peer.pc.addIceCandidate(new RTCIceCandidate(candidate));
|
||||
await this.peer.pc.addIceCandidate(new this.peer.RTCIceCandidate(candidate));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user