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 · Marking, scores and game rules

kotobaLanguagefunction

The language a person asked for, by en or ja or a tag that begins with one: English for anything else.

Import it

import { kotobaLanguage } from "@johnmorrisdotca/kotoba";

Definition

function kotobaLanguage(tag: string | undefined): Language

Parameters

NameTypeDescription
tagstring | undefined

A language tag, or undefined to select English.

Returns

Language

The language a person asked for, by en or ja or a tag that begins with one: English for anything else.

Examples

import { kotobaLanguage } from "@johnmorrisdotca/kotoba";

console.log(kotobaLanguage("ja-JP"));
ja

What it prints (run when this page was built)

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