Open yugkha3 opened 2 years ago
peers[connectedUserSocketID].on('stream', (stream) => { streams.set(connectedUserSocketID, stream); store.dispatch(setStreams({ connectedUserSocketID })); });
When i only use the above event listner 'stream' everything works fine. But when I use both the below 'stream' and 'data' event listners the 'stream' event does not trigger properly. Here's the code with both stream listners:
peers[connectedUserSocketID].on('stream', (stream) => { streams.set(connectedUserSocketID, stream); store.dispatch(setStreams({ connectedUserSocketID })); }); peers[connectedUserSocketID].on('data', (data) => { const messageData = JSON.parse(data); appendMessage(messageData); })
I've got the same problem. Have you got it fixed yet?🤣
no man, wbu?
I have the same problem too.
When i only use the above event listner 'stream' everything works fine. But when I use both the below 'stream' and 'data' event listners the 'stream' event does not trigger properly. Here's the code with both stream listners: