diff --git a/src/TicTacToe/Root.tsx b/src/TicTacToe/Root.tsx index 406907e..0a59e53 100644 --- a/src/TicTacToe/Root.tsx +++ b/src/TicTacToe/Root.tsx @@ -104,7 +104,7 @@ function TicTacToe() { const callback = () => { playTurn(index); }; - return ; + return ; })} @@ -113,19 +113,12 @@ function TicTacToe() { interface CellProps { state: number; - callback: () => void; + onClick: () => void; } -function TicTacToeCell({ state, callback }: CellProps) { - function handleClick() { - callback(); - } - +function TicTacToeCell({ state, onClick }: CellProps) { return ( -
+

{getStateChar(state)}

);