From bf564d3f053e86d0f36a95a646bf7f75c1ed372e Mon Sep 17 00:00:00 2001 From: Epid Date: Tue, 24 Mar 2026 13:51:16 +0300 Subject: [PATCH] fix(websocket): remove export{} from sharedworker entry point, rename worker MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Remove `export {}` which caused webpack to tree-shake the entire SharedWorker bundle, resulting in an empty JS file with no connect handler — root cause of WebSocket never opening - Rename SharedWorker instance from 'notification-worker' to 'notification-worker-ws' to force browser to create a fresh worker instance instead of reusing a cached empty one --- web_src/js/features/websocket.sharedworker.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/web_src/js/features/websocket.sharedworker.ts b/web_src/js/features/websocket.sharedworker.ts index f8cc635570..9925ba5bd6 100644 --- a/web_src/js/features/websocket.sharedworker.ts +++ b/web_src/js/features/websocket.sharedworker.ts @@ -1,7 +1,5 @@ // One WebSocket connection per URL, shared across all tabs via SharedWorker. // Messages from the server are JSON objects broadcast to all connected ports. -export {}; // make this a module to avoid global scope conflicts with other sharedworker files - const RECONNECT_DELAY_INITIAL = 50; const RECONNECT_DELAY_MAX = 10000;