Reference · Rockets, variants, parts and the fit check
Descriptiontype
A rocket to check or build: its id, its variant (left out: the rocket's default) and any other part in a slot, by part id.
Import it
import type { Description } from "@johnmorrisdotca/uchusen-rockets";
Definition
interface Description {
rocket: string;
variant?: string;
parts?: Readonly<Record<string, string>>;
form?: "stack" | "space";
}
Members
| Name | Type | Description |
|---|---|---|
rocket | string | |
variant (optional) | string | undefined | Left out: the rocket's default variant. |
parts (optional) | Readonly<Record<string, string>> | undefined | Another part in a slot, by its id. |
form (optional) | "stack" | "space" | undefined |
|
Examples
import { check, type Description } from "@johnmorrisdotca/uchusen-rockets";
const description: Description = { rocket: "starship", variant: "v3", parts: { ship: "starship-v2-ship" } };
console.log(check(description).label);Custom build, not a vehicle that flew: Super Heavy, Block 3 (V3) with Ship, Block 2 (V2)What it prints (run when this page was built)