react-use-websocket icon indicating copy to clipboard operation
react-use-websocket copied to clipboard

React Hook for WebSocket communication

Results 69 react-use-websocket issues
Sort by recently updated
recently updated
newest added

When someone sends a lot of events to the socket (~ 5-10 per second), it locks the main thread completely, until messages stop. Consider using webworkers.

Hi, thanks for putting together a useful package. Unfortunately, it's difficult to use or recommend without releases or a CHANGELOG. There are tools to automate the creation of these things...

Hey, I have been experimenting with the heartbeat feature and as reported on comment https://github.com/robtaussig/react-use-websocket/pull/206#issuecomment-1867894798 , this seems not sending any messages via websocket. ``` const { sendMessage, sendJsonMessage, lastJsonMessage,...

Noticed that internals of this hook use flushSync to force updates, but is there a strong reason for this as opposed to other approaches? FlushSync use is generally discouraged and...

![image](https://github.com/robtaussig/react-use-websocket/assets/101227957/b984be21-9aee-4f8f-a3ab-66cce0650fe4) It was found that after calling useWebsocket and opening the ws connection, an undefined message appeared in the ws cache queue for unknown reasons. After traversing the cache queue,...

@robtaussig I love the library you built and how it handles a lot of the additional work of reconnecting, etc. We use `redux-saga` extensively in our application for side effects...

I set usewebsocket on the root of component. If user lost connection and reconnect attempt has exceeded, how can I handle the reconnection?

I was wondering if the patch that added generics to lastJsonMessage can be back-ported to 3.0 version, for projects that still use React 16 and want the type-safety. The patch...

I run into a situation when useEffect invocation was skipped during a higher number of incoming events two scenarios to compare: 1. websocket receives 30 events with a delay 1...

Using last version of [socket.io 4.x](https://github.com/socketio/socket.io) cause exception in browser: ``` create-or-join.ts:63 WebSocket connection to 'ws://localhost:3003/socket.io/?EIO=3&transport=websocket' failed: Invalid frame header ``` Which is usually means socket server/client version mismatch. To...