Skip to the content

Tobiishi飛び石

Jump pegs on nine native boards, generate seeded solvable challenges and build a peg-solitaire player for your page.

Tobiishi is the Japanese word 飛び石 for stepping stones. About the name

Contents

Reference · Boards, rules and challenges

TOBIISHI_CHALLENGE_PACKSconstant

Named challenge pack metadata; each goal is a distinct hole with a legal witness.

Import it

import { TOBIISHI_CHALLENGE_PACKS } from "@johnmorrisdotca/tobiishi";

Definition

const TOBIISHI_CHALLENGE_PACKS: Readonly<Record<Shape, Readonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>>>

Members

NameTypeDescription
englishReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
europeanReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
triangleReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
diamondReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
heartReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
starReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
hexagonReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
wideReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>
tallReadonly<{ title: Readonly<Record<"en" | "ja", string>>; shape: Shape; goals: readonly GoalHole[]; }>

Examples

import { TOBIISHI_CHALLENGE_PACKS } from "@johnmorrisdotca/tobiishi";

console.log(Object.keys(TOBIISHI_CHALLENGE_PACKS));
[
  'english',  'triangle',
  'european', 'diamond',
  'heart',    'star',
  'hexagon',  'wide',
  'tall'
]

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tobiishi 0.3.1.