Fixed connecting to local server hanging on some browsers

This commit is contained in:
RemixDev 2022-01-12 19:40:05 +01:00
parent 2e20c6cd91
commit e8cec91c7d

View File

@ -59,6 +59,7 @@ export default {
} }
}, },
mounted() { mounted() {
this.isSocketConnected = socket.readyState === WebSocket.OPEN
socket.addEventListener('open', () => { socket.addEventListener('open', () => {
console.log('Connected to WebSocket') console.log('Connected to WebSocket')
this.isSocketConnected = true this.isSocketConnected = true