Skip to the content

Kumimoji組み文字

Build crosswords from seeded English or Japanese tile bags, alone or at a shared table.

Kumimoji means assembled characters in Japanese. About the name

Contents

Reference · Rules, tiles and records

readTileProgressfunction

The parts of a kept game, or null for a string that is not one: its shape only, with no bag to check it against.

Import it

import { readTileProgress } from "@johnmorrisdotca/kumimoji";

Definition

function readTileProgress(code: string): { taken: number; returned: string; hand: string[]; tiles: Map<string, string>; } | null

Parameters

NameTypeDescription
codestring

The encoded grid or progress text.

Returns

{ taken: number; returned: string; hand: string[]; tiles: Map<string, string>; } | null

The parts of a kept game, or null for a string that is not one: its shape only, with no bag to check it against.

Examples

import { deal, encodeTileProgress, readTileProgress } from "@johnmorrisdotca/kumimoji";

const play = deal("catdog",3);
console.log(readTileProgress(encodeTileProgress(play)));
{ taken: 3, returned: '', hand: [ 'c', 'a', 't' ], tiles: Map(0) {} }

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/kumimoji 1.6.0.