formatCountry()function
formatCountry(country: string): string
| Param | Type | |
|---|---|---|
country | string | The country code to format. required |
| Return | |
|---|---|
string | The full English country name, or the input unchanged if it is not a known code. |
Format a country code into its full country name.
- Matching is case-insensitive; unknown codes are returned unchanged.
Examples
formatCountry("GB") // "United Kingdom"