This example demonstrates live streaming capabilities. Key features:
type: 'live' - Enables live streaming modeprobeInterval: 5000 - Probe interval in milliseconds (default: 5000)maxProbeAttempts: 12 - Maximum probe attempts (default: 12)onProbeSuccess - Callback when probe succeedsonProbeFailed - Callback when all probe attempts failconst player = new VSRCPlayer('#live-player', {
type: 'live',
mediaId: 'my-live-stream-123',
probeInterval: 5000,
maxProbeAttempts: 12,
onProbeSuccess: (player) => {
console.log('Stream found and starting playback');
},
onProbeFailed: (player) => {
console.error('Stream not available after all attempts');
}
});