roundName関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
The name of a round that has remaining teams left in it, counting from the final: Final, Semi-finals, Quarter-finals, Round of 16…
インポート
import { roundName } from "@johnmorrisdotca/taisen-brackets/layout";
ほかのエクスポート元: @johnmorrisdotca/taisen-brackets/presets, @johnmorrisdotca/taisen-brackets
定義
function roundName(remaining: number): string
引数
| 名前 | 型 | 説明 |
|---|---|---|
remaining | number | How many teams are left in the round: 2 is the final, 4 the semi-finals, 8 the quarter-finals. |
戻り値
string
The round's English name.
例
import { roundName } from "@johnmorrisdotca/taisen-brackets";
console.log([2, 4, 8, 16].map((teams) => roundName(teams)));[ 'Final', 'Semi-finals', 'Quarter-finals', 'Round of 16' ]出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。