Explore / React

Chessboard

Medium · React

What to build

Render an 8×8 chess board with alternating squares. When a cell is clicked, highlight it and every cell diagonally connected to it. Clicking the same cell again deselects everything.

Build it in the browser editor on GrindPrep (desktop) and compare with the reference solution.