Skip to the content

Tenka天下

Play seeded world conquest for two to six, with dice battles, cards, computer players and saved games.

Tenka means the world under heaven in Japanese. About the name

Contents

Reference · Rules, maps and records

cleanTenkaNamefunction

A name as the table typed it, tidied: spaces run together, trimmed, cut to TENKA_NAME_MOST.

Import it

import { cleanTenkaName } from "@johnmorrisdotca/tenka";

Definition

function cleanTenkaName(name: string): string

Parameters

NameTypeDescription
namestring

The player name to clean for display.

Returns

string

A name as the table typed it, tidied: spaces run together, trimmed, cut to TENKA_NAME_MOST.

Examples

import { cleanTenkaName } from "@johnmorrisdotca/tenka";

console.log(cleanTenkaName("  Seat 1  "));
Seat 1

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tenka 2.2.0.