feat: SSE live fight spectating with spectator count
Enable real-time fight spectating for all live fights (not just human fights). Multiple spectators can watch simultaneously via SSE. Spectator count is tracked per-fight and broadcast with every SSE event. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
a540320901
commit
610e799605
@@ -55,8 +55,23 @@ export default defineConfig({
|
||||
},
|
||||
}),
|
||||
],
|
||||
worker: {
|
||||
format: 'es', // Required for dynamic import('kokoro-js') inside the TTS worker
|
||||
},
|
||||
optimizeDeps: {
|
||||
// Pre-bundle kokoro-js on first startup so Vite doesn't stall mid-page-load
|
||||
// discovering it as a new dep. The 4.8MB bundle is cached in node_modules/.vite/deps.
|
||||
include: ['kokoro-js'],
|
||||
},
|
||||
server: {
|
||||
port: 9101,
|
||||
headers: {
|
||||
// Enable SharedArrayBuffer for onnxruntime WASM threads.
|
||||
// Without these, Kokoro TTS runs single-threaded on the main thread,
|
||||
// blocking the UI for seconds on every TTS generation.
|
||||
'Cross-Origin-Opener-Policy': 'same-origin',
|
||||
'Cross-Origin-Embedder-Policy': 'credentialless',
|
||||
},
|
||||
proxy: {
|
||||
'/api': {
|
||||
target: 'http://localhost:9100',
|
||||
|
||||
Reference in New Issue
Block a user