chesster.js
v0.0.4
Published
A TypeScript chess library focused on performance and accuracy.
Downloads
13
Readme
chesster.js
A TypeScript chess library focused on performance and accuracy.
Features
- Fast move generation using bit-manipulation
- Full chess rules (castling, en passant, promotion)
- Fivefold repetition stalemate draw
- Move history and undo
- FEN string import
- Check, checkmate, and stalemate detection
Installation
npm install chesster.jsUsage
import { Chesster } from "chesster.js";
// Create a new game
const game = new Chesster();
// Get all legal moves
const moves = game.moves();
// Make a move
game.move(moves[0]);
// Undo a move
game.undo();
// Check if game is over
if (game.isGameOver()) {
console.log("gg");
}Planned features
- FEN string export
- MORE PERFORMANCE!
License
ISC
