craftName関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
The words that name one craft in a picture of several: its name, then its length in metres, such as "Saturn V (Apollo), 110.64 m". A real craft's length is its sourced height when a source gave one; otherwise the model's own height in the picture, tall.
インポート
import { craftName } from "@johnmorrisdotca/uchusen-rockets";
定義
function craftName(description: Readonly<Description>, tall: number): string
引数
| 名前 | 型 | 説明 |
|---|---|---|
description | Readonly<Description> | The craft's rocket and variant. |
tall | number | The height of its model, in metres, used when no source gave its length. |
戻り値
string
The label.
例
import { craftName } from "@johnmorrisdotca/uchusen-rockets";
console.log(craftName({ rocket: "saturn-v", variant: "saturn-v" }, 110.6));Saturn V (Apollo), 110.64 m出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。