A TypeScript chess library for move generation, validation, and game state detection.
chess.js is a TypeScript library that implements core chess logic, including move generation, validation, piece movement, and detection of game states like check, checkmate, and stalemate. It provides everything needed to build chess applications except for AI components.
Developers building chess applications, such as game engines, analysis tools, or educational software, who need reliable chess logic without implementing the rules from scratch.
It offers a well-tested, lightweight, and easy-to-integrate solution for chess logic, saving developers time and ensuring rule accuracy across both Node.js and browser environments.
A TypeScript chess library for chess move generation/validation, piece placement/movement, and check/checkmate/draw detection
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Generates all legal moves for any board position, ensuring accurate gameplay logic as demonstrated in the example code for random move selection.
Detects check, checkmate, stalemate, and draws reliably, core to its design for handling chess rules without AI.
Provides built-in PGN output via chess.pgn(), facilitating easy game recording and sharing for analysis tools.
Extensively tested in Node.js and modern browsers, making it a dependable choice for cross-environment applications.
Explicitly omits chess AI, requiring developers to implement or integrate separate engines for intelligent gameplay, as stated in the README.
Focused on traditional chess, lacking support for variants without modification, which can restrict flexibility for innovative projects.
Provides no graphical components, necessitating additional libraries like chessboard.js for board visualization and user interaction.