Enhance Socket.IO integration and improve error handling

- Updated CORS configuration for Socket.IO to allow all origins and added specific allowed headers.
- Improved error handling for Socket.IO connections, including detailed logging for connection errors and upgrade attempts.
- Implemented cleanup logic for socket connections during page reloads to prevent stale connections.
- Enhanced reconnection logic with unlimited attempts and improved logging for connection status.
- Updated frontend socket service to manage club room joining and leaving more effectively, with better state handling.
- Configured Vite for improved hot module replacement (HMR) settings to support local development.
This commit is contained in:
Torsten Schulz (local)
2025-11-29 00:52:29 +01:00
parent bf0d5b0935
commit a651113dee
4 changed files with 270 additions and 20 deletions

View File

@@ -13,6 +13,11 @@ export default defineConfig({
port: 5000,
watch: {
usePolling: true,
},
hmr: {
protocol: 'ws',
host: 'localhost',
port: 5000,
}
},
});