customName関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A custom flag's name, in English or Japanese (any tag that starts ja); the English where no Japanese was given.
インポート
import { customName } from "@johnmorrisdotca/hata/custom";
定義
function customName(id: string, lang?: string): string | null
引数
| 名前 | 型 | 説明 |
|---|---|---|
id | string | The flag's id, in any case. |
lang (省略可) | string |
|
戻り値
string | null
The name, or null when no such flag is registered.
例
import { customName } from "@johnmorrisdotca/hata/custom";
console.log(customName("custom:nothing-here", "ja")); // nullnull出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。