perf: Reduce reconnect delay from 500ms to 200ms for faster response

Optimized the timeout after stream reconnection to make the pause/unpause
experience more responsive. The 200ms delay is sufficient for the browser
to clear buffers and start the fresh stream while minimizing perceived lag.
This commit is contained in:
Glenn Thompson 2025-12-06 10:13:42 +03:00
parent 2117832812
commit 929d7ceeeb
4 changed files with 4 additions and 4 deletions

View File

@ -158,7 +158,7 @@ window.addEventListener('DOMContentLoaded', function() {
} }
isReconnecting = false; isReconnecting = false;
}, 500); }, 200);
} }
}); });

View File

@ -74,7 +74,7 @@ document.addEventListener('DOMContentLoaded', function() {
} }
isReconnecting = false; isReconnecting = false;
}, 500); }, 200);
} }
}); });
} }

View File

@ -94,7 +94,7 @@
} }
isReconnecting = false; isReconnecting = false;
}, 500); }, 200);
} else { } else {
console.log('Audio playing'); console.log('Audio playing');
} }

View File

@ -181,7 +181,7 @@
} }
isReconnecting = false; isReconnecting = false;
}, 500); }, 200);
} }
}); });