Releases: echecsjs/game
Releases · echecsjs/game
v2.0.2
v2.0.1
Fixed
- Corrected README to match 2.0.0 API: removed nonexistent
Game.fromFen()and
game.fen(), documentednew Game(position)constructor, fixedundo()/
redo()return types (void, notthis), fixedMove.promotionsignature,
removedMoveInputfrom exports listing. - Updated
AGENTS.mdto reflect single runtime dependency (@echecs/position),
removed nonexistentsrc/fen.ts, added missing test files, removed stale
references toisAttacked/applyMoveToState, updated naming convention
examples. - Changed
package.jsonkeyword fromno-dependenciesto
minimal-dependencies.
v2.0.0
Changed
- BREAKING: upgraded to
@echecs/positionv3.Colorvalues are now
'white'/'black'(was'w'/'b').PieceTypevalues are now full words
('pawn','knight','bishop','rook','queen','king') instead of
single letters. - BREAKING:
CastlingRightsshape is now
{ white: { king, queen }, black: { king, queen } }(was
{ wK, wQ, bK, bQ }). - BREAKING:
PromotionPieceTypeuses full words ('queen','rook',
'bishop','knight') instead of single letters. - BREAKING: constructor now accepts an optional
Positionargument instead
of always starting from the initial position.new Game()still defaults to
the starting position;new Game(position)starts from anyPosition. - BREAKING:
MoveInputtype merged intoMovewith optionalpromotion.
Game.move()now takesMovedirectly. - Rewrote move generation to use
position.reach()for pseudo-legal targets and
position.derive()+isCheckfor legality filtering. Removed all 0x88
internal board manipulation. @echecs/fenmoved from runtime dependency to devDependency. FEN
parsing/serialization is no longer part of the public API.
Added
- Local
MoveandPromotionPieceTypetypes (removed from@echecs/position
v3). - Re-exported
STARTING_POSITION,EnPassantSquare, andSideCastlingRights
from@echecs/position. - Full game playthrough test (81-move Fischer-Spassky 1972 Game 6) via
@echecs/san. - Zobrist hash consistency tests (move/undo cycles, transpositions).
- Regression edge-case tests ported from chess.js.
Removed
- BREAKING:
Game.fromFen()static method — construct aPositionand pass
it tonew Game(position)instead. - BREAKING:
game.fen()method — use@echecs/fendirectly with
game.position(). - BREAKING:
isAttacked()method — removed fromGame. Position v3 no
longer exposes attack queries.
v1.1.0
Added
Game.isAttacked(square, color)— returnstrueif any piece ofcolor
attackssquare. Matches chess.js semantics: pinned pieces still attack, own
pieces count as attacked squares, no X-ray, same square returnsfalse.
v1.0.0
Changed
- First stable release. No API changes from
0.1.1.