Skip to the content

Taisen Brackets対戦

Knockout brackets as SVG, from a list of ties.

Taisen (対戦, たいせん) is Japanese for a matchup: two sides facing each other. About the name

Contents

Reference · Ready-made formats for each league

PlayoffRoundtype

One round of a playoff format: its name and how many games a series is (null for a single game).

Import it

import type { PlayoffRound } from "@johnmorrisdotca/taisen-brackets/presets";

Also exported from: @johnmorrisdotca/taisen-brackets

Definition

interface PlayoffRound {
    name: string;
    bestOf: number | null;
}

Members

NameTypeDescription
namestring

The round's name as the league calls it.

bestOfnumber | null

The length of the series, or 1 for a single game; null when the round is two legs or a group stage.

Examples

import { playoffFormat, type PlayoffRound } from "@johnmorrisdotca/taisen-brackets";

const rounds: PlayoffRound[] = playoffFormat("nba", 2024)?.rounds ?? [];
console.log(rounds.map((round) => `${round.name}: ${round.bestOf}`));
[
  'First Round: 7',
  'Conference Semifinals: 7',
  'Conference Finals: 7',
  'NBA Finals: 7'
]

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/taisen-brackets 0.20.0.