diff --git a/src/tictactoe/TicTacToe.tsx b/src/tictactoe/TicTacToe.tsx index d02b82b..c3174f2 100644 --- a/src/tictactoe/TicTacToe.tsx +++ b/src/tictactoe/TicTacToe.tsx @@ -38,24 +38,24 @@ export default function TicTacToe() { }); }, [onMatchData]); - useEffect(() => { - let active = true; - - async function refreshLoop() { - while (active) { - const matches = await listOpenMatches(); - setOpenMatches(matches); - - await new Promise(res => setTimeout(res, 500)); // 0.5s refresh - } - } - - refreshLoop(); - - return () => { - active = false; - }; - }, [listOpenMatches]); + // useEffect(() => { + // let active = true; + // + // async function refreshLoop() { + // while (active) { + // const matches = await listOpenMatches(); + // setOpenMatches(matches); + // + // await new Promise(res => setTimeout(res, 500)); // 0.5s refresh + // } + // } + // + // refreshLoop(); + // + // return () => { + // active = false; + // }; + // }, [listOpenMatches]); // ------------------------------------------ // CONNECT @@ -130,8 +130,8 @@ export default function TicTacToe() { {/* Join matchmaking */} - {/* List open matches */} - + {/*/!* List open matches *!/*/} + {/**/} )}