The Intl.DisplayNames API provides localized names of language, region, script, and currency codes.
Intl.DisplayNames