Skip to the content

Jarajaraジャラジャラ

Draw mahjong tiles, arrange racks and stacked boards, and play seeded Awase alone or at a shared table.

Jarajara is the Japanese sound of mahjong tiles rattling together. About the name

Contents

Reference · Tiles, layouts and deals

geometryOffunction

What lies on and beside each slot, worked out once for a layout and kept.

Import it

import { geometryOf } from "@johnmorrisdotca/jarajara";

Definition

function geometryOf(layout: MahjongLayout): MahjongGeometry

Parameters

NameTypeDescription
layoutMahjongLayout

The native stacked tile positions.

Returns

MahjongGeometry

What lies on and beside each slot, worked out once for a layout and kept.

Examples

import { geometryOf, layoutFor } from "@johnmorrisdotca/jarajara";

const layout = layoutFor(4)!;
console.log(geometryOf(layout).above.length);
8

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/jarajara 1.7.0.