Reference · Rockets, variants, parts and the fit check
FitCodetype
Why a check said what it said: an unknown rocket, variant, slot or part, a part of the wrong kind, a joint that is missing, of another kind or of another width, or a custom build.
Import it
import type { FitCode } from "@johnmorrisdotca/uchusen-rockets";
Definition
type FitCode = "unknown-rocket" | "unknown-variant" | "unknown-slot" | "unknown-part" | "wrong-kind" | "no-joint" | "joint-kind" | "joint-diameter" | "custom";
Examples
import { check, type FitCode } from "@johnmorrisdotca/uchusen-rockets";
const codes: FitCode[] = check({ rocket: "nowhere" }).issues.map((issue) => issue.code);
console.log(codes);[ 'unknown-rocket' ]What it prints (run when this page was built)