Skip to the content

Kotoba言葉

Load only the word lists you need, mark repeated letters correctly and play a daily or seeded word game.

Kotoba is the Japanese word for words. About the name

Contents

Reference · Playable game

mountKotobafunction

Put a word game into container, and deal the first round.

Import it

import { mountKotoba } from "@johnmorrisdotca/kotoba/play";

Definition

function mountKotoba(container: HTMLElement, options?: KotobaPlayOptions): KotobaPlay

Parameters

NameTypeDescription
containerHTMLElement

The HTMLElement that owns the native interface.

options (optional)KotobaPlayOptions

Native settings and callbacks for this mounted interface.

Returns

KotobaPlay

The native mounted handle, including controls and destroy() cleanup.

Examples

import { mountKotoba } from "@johnmorrisdotca/kotoba/play";
const show = (host: HTMLElement, options: Parameters<typeof mountKotoba>[1]) => mountKotoba(host, options);
console.log(typeof show); // function
function

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/kotoba 1.2.0.