Reference · Rules, games and records
formatOpeningfunction
One line of a game: the opening throw.
Import it
import { formatOpening } from "@johnmorrisdotca/sugoroku";
Definition
function formatOpening(throws: readonly [number, number]): string
Parameters
| Name | Type | Description |
|---|---|---|
throws | readonly [number, number] | The opening die for white, then black. |
Returns
string
One line of a game: the opening throw.
Examples
import { formatOpening } from "@johnmorrisdotca/sugoroku";
console.log(formatOpening([3,1]));open 3 1What it prints (run when this page was built)