Reference · Satellites: orbital elements in, positions out
ownerCountryfunction
The country of a satellite's owner code as an ISO 3166-1 alpha-2 code (PRC is CN, PAKI is PK, US is US), or undefined for an organisation, several countries, an ambiguous owner or a code that is not in the list.
Import it
import { ownerCountry } from "@johnmorrisdotca/chikyu-earth/satellites";
Also exported from: @johnmorrisdotca/chikyu-earth/catalogue
Definition
function ownerCountry(code: string | null | undefined): string | undefined
Parameters
| Name | Type | Description |
|---|---|---|
code | string | null | undefined | The owner code as the catalogue writes it ( |
Returns
string | undefined
The two-letter country code, or undefined.
Examples
import { ownerCountry } from "@johnmorrisdotca/chikyu-earth/satellites";
console.log(ownerCountry("PRC"), ownerCountry("PAKI"), ownerCountry("ESA"), ownerCountry("XYZ"));CN PK undefined undefinedWhat it prints (run when this page was built)