fix: connection status
This commit is contained in:
parent
5f932db5f6
commit
fdd176644a
|
@ -42,6 +42,7 @@ const ConnectionComponent = ({
|
||||||
const [isConnected, setIsConnected] = useState(false);
|
const [isConnected, setIsConnected] = useState(false);
|
||||||
// Juggle connected state.
|
// Juggle connected state.
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
setIsConnected(socket.isConnected);
|
||||||
const onConnect = () => {
|
const onConnect = () => {
|
||||||
setIsConnected(true);
|
setIsConnected(true);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user