makeMoveWithPromotion method
void
makeMoveWithPromotion({})
Makes move and promotes pawn to piece (from is a square like d4, to is also a square like e3, pieceToPromoteTo is a String like "Q". pieceToPromoteTo String will be changed to enum in a future update and this method will be deprecated in the future
Implementation
void makeMoveWithPromotion(
{required String from,
required String to,
required String pieceToPromoteTo}) {
game.move({"from": from, "to": to, "promotion": pieceToPromoteTo});
notifyListeners();
}