chore: format repo and fix lint config

This commit is contained in:
Yahya Alhinai
2026-06-28 00:09:48 +00:00
parent 1294b8428d
commit b1b0761973
23 changed files with 198 additions and 104 deletions
+3 -1
View File
@@ -15,7 +15,9 @@ export function useInterventions(room: Room | null) {
if (msg.type === 'COLLISION') setActive(msg.intervention);
};
room.on(RoomEvent.DataReceived, onData);
return () => { room.off(RoomEvent.DataReceived, onData); };
return () => {
room.off(RoomEvent.DataReceived, onData);
};
}, [room]);
const respond = useCallback(
+11 -8
View File
@@ -7,14 +7,17 @@ export function useScreenPublish() {
const [connected, setConnected] = useState(false);
const [sharing, setSharing] = useState(false);
const join = useCallback(async (pod: string, identity: string, name: string, githubLogin?: string) => {
const { token, url } = await fetchToken({ room: pod, identity, name, githubLogin });
const room = new Room({ adaptiveStream: true, dynacast: true });
await room.connect(url, token);
roomRef.current = room;
setConnected(true);
return room;
}, []);
const join = useCallback(
async (pod: string, identity: string, name: string, githubLogin?: string) => {
const { token, url } = await fetchToken({ room: pod, identity, name, githubLogin });
const room = new Room({ adaptiveStream: true, dynacast: true });
await room.connect(url, token);
roomRef.current = room;
setConnected(true);
return room;
},
[],
);
const startSharing = useCallback(async () => {
const room = roomRef.current;