mirror of
https://github.com/xtr-dev/rondevu-client.git
synced 2025-12-10 02:43:25 +00:00
- Add RondevuService: High-level API for username claiming and service publishing with Ed25519 signatures - Add ServiceHost: Manages offer pool for hosting services with auto-replacement - Add ServiceClient: Connects to hosted services with automatic reconnection - Add NoOpSignaler: Placeholder signaler for connection setup - Integrate Ed25519 signature functionality from @noble/ed25519 - Add ESLint and Prettier configuration with 4-space indentation - Add demo with local signaling test - Version bump to 0.10.0 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
36 lines
1.2 KiB
TypeScript
36 lines
1.2 KiB
TypeScript
import { Signaler } from './types'
|
|
|
|
export class WebRTCContext {
|
|
constructor(public readonly signaler: Signaler) {}
|
|
|
|
createPeerConnection(): RTCPeerConnection {
|
|
return new RTCPeerConnection({
|
|
iceServers: [
|
|
{
|
|
urls: 'stun:stun.relay.metered.ca:80',
|
|
},
|
|
{
|
|
urls: 'turn:standard.relay.metered.ca:80',
|
|
username: 'c53a9c971da5e6f3bc959d8d',
|
|
credential: 'QaccPqtPPaxyokXp',
|
|
},
|
|
{
|
|
urls: 'turn:standard.relay.metered.ca:80?transport=tcp',
|
|
username: 'c53a9c971da5e6f3bc959d8d',
|
|
credential: 'QaccPqtPPaxyokXp',
|
|
},
|
|
{
|
|
urls: 'turn:standard.relay.metered.ca:443',
|
|
username: 'c53a9c971da5e6f3bc959d8d',
|
|
credential: 'QaccPqtPPaxyokXp',
|
|
},
|
|
{
|
|
urls: 'turns:standard.relay.metered.ca:443?transport=tcp',
|
|
username: 'c53a9c971da5e6f3bc959d8d',
|
|
credential: 'QaccPqtPPaxyokXp',
|
|
},
|
|
],
|
|
})
|
|
}
|
|
}
|