canShrinkBoardfunction
Whether resizing is enabled and a smaller native board is available.
Import it
import { canShrinkBoard } from "@johnmorrisdotca/narabe";
Definition
function canShrinkBoard(state: GameState): boolean
Parameters
| Name | Type | Description |
|---|---|---|
state | GameState | The current immutable game position. |
Returns
boolean
Whether resizing is enabled and a smaller native board is available.
Examples
import { canShrinkBoard, createGame } from "@johnmorrisdotca/narabe";
const state = createGame({variant:"freestyle",size:15});
console.log(canShrinkBoard(state));falseWhat it prints (run when this page was built)