feat: add cache busting and hls query param

This commit is contained in:
2026-06-14 21:51:02 +02:00
parent f9f3322797
commit 4a74fdcf31
8 changed files with 23 additions and 6 deletions

View File

@@ -5,6 +5,9 @@ export const streamUrlForMode = (mode: string, quality?: string): string => {
if (!src?.token) return "";
let url = `${state.streamURL}?mode=${encodeURIComponent(mode)}&token=${encodeURIComponent(src.token)}`;
if (src.type === "m3u8") {
url += "&hls=1";
}
if (quality && quality !== "best") {
url += `&quality=${encodeURIComponent(quality)}`;
}