Reference · Rules, tiles and records
tilesLeftfunction
How many tiles are still in the bag.
Import it
import { tilesLeft } from "@johnmorrisdotca/kumimoji";
Definition
function tilesLeft(play: TilePlay): number
Parameters
| Name | Type | Description |
|---|---|---|
play | TilePlay | The current immutable solo-game progress. |
Returns
number
How many tiles are still in the bag.
Examples
import { deal, tilesLeft } from "@johnmorrisdotca/kumimoji";
const play = deal("catdog",3);
console.log(tilesLeft(play));3What it prints (run when this page was built)