$ quick-start
Install and render in seconds
terminal
$ npm install @mdwebb/react-chessapp.tsx
import { Chessboard } from "@mdwebb/react-chess";
import "@mdwebb/react-chess/styles";
function App() {
return (
<Chessboard
width={500}
height={500}
theme="brown"
showMoveHistory={true}
showNavigation={true}
onMove={(from, to, move) => {
console.log(move.san);
}}
/>
);
}$ features --list
Everything included
custom_themes
4 presets or build your own with live pickers
pgn_support
Annotations, NAG symbols, comments, metadata
compound_api
Compose Board, MoveHistory, Navigation
promotion_ui
Visual piece selection dialog
keyboard_nav
Arrow keys to step through moves
callbacks
onCheck, onGameOver, onIllegalMove
board_flip
Toggle via button, prop, or ref
typescript
Every prop, callback, and ref typed
$ demos --interactive
Explore every feature live