rinvex / countries

Rinvex Country is a simple and lightweight package for retrieving country details with flexibility. A whole bunch of data including name, demonym, capital, iso codes, dialling codes, geo data, currencies, flags, emoji, and other attributes for all 250 countries worldwide at your fingertips.
https://rinvex.com
MIT License
1.64k stars 206 forks source link

Italy native name and main language #226

Closed costafrancesco94 closed 1 year ago

costafrancesco94 commented 2 years ago

Hello :)

I would like to point out an issue...

In Italy files, we have the 3 translation of the common and official name in the native languages.

Problem is, main language of Italy is wrong (it does return the first one, not the main one)

getLanguage() // "Austro-Bavarian German"
getLanguages() // Object { bar: "Austro-Bavarian German", ita: "Italian", srd: "Sardinian" }

Problem is there is no way to determine what is the main language of the country.

Omranic commented 1 year ago

@costafrancesco94 thank you for pointing this out, I believe this needs cleaning and a fix similar to what we did with the currency here https://github.com/rinvex/countries/commit/1cf372b29bc0c17eeaf08e40a7cd98b729aae296

All PRs are welcome 🙂 🙌