           socket.send(sdp);
              }
            };
            peer.oniceconnectionstatechange = () => {
              console.log(
                "oniceconnectionstatechange",
                peer.iceConnectionState
              );
            };
            peer.ontrack = (e) => {
              console.log("ontrack", e);
              remoteRef.current.srcObject = e.streams[0];
            };
            const localStream = await navigator.mediaDevices.getUserMedia({
              video: true,
