GithubHelp home page GithubHelp logo

wooorm / iso-3166 Goto Github PK

View Code? Open in Web Editor NEW
68.0 4.0 13.0 674 KB

ISO 3166 (standard for country codes and codes for their subdivisions)

License: MIT License

JavaScript 100.00%
iso-3166 iso-3166-1 iso-3166-2 iso-3166-3 country subdivision territory state region iso code

iso-3166's Issues

Trouble retrieving English names for South African provinces

For some reason I have yet to figure out, the English names for South African provinces aren't being consistently retrieved:

iso-3166/2.js

Lines 25208 to 25252 in 7aacab6

{
code: 'ZA-EC',
name: 'Kapa-Vuxa',
parent: 'ZA'
},
{
code: 'ZA-FS',
name: 'Free State',
parent: 'ZA'
},
{
code: 'ZA-GP',
name: 'Gauteng',
parent: 'ZA'
},
{
code: 'ZA-KZN',
name: 'Kwazulu-Natal',
parent: 'ZA'
},
{
code: 'ZA-LP',
name: 'Limpopo',
parent: 'ZA'
},
{
code: 'ZA-MP',
name: 'Mpumalanga',
parent: 'ZA'
},
{
code: 'ZA-NC',
name: "Kapa-N'walungu",
parent: 'ZA'
},
{
code: 'ZA-NW',
name: "N'walungu-Vupeladyambu",
parent: 'ZA'
},
{
code: 'ZA-WC',
name: 'Kapa-Vupeladyambu',
parent: 'ZA'
},

For reference it should be:

  {
    code: 'ZA-EC',
    name: 'Eastern Cape',
    parent: 'ZA'
  },
  {
    code: 'ZA-FS',
    name: 'Free State',
    parent: 'ZA'
  },
  {
    code: 'ZA-GP',
    name: 'Gauteng',
    parent: 'ZA'
  },
  {
    code: 'ZA-KZN',
    name: 'Kwazulu-Natal',
    parent: 'ZA'
  },
  {
    code: 'ZA-LP',
    name: 'Limpopo',
    parent: 'ZA'
  },
  {
    code: 'ZA-MP',
    name: 'Mpumalanga',
    parent: 'ZA'
  },
  {
    code: 'ZA-NC',
    name: 'Northern Cape',
    parent: 'ZA'
  },
  {
    code: 'ZA-NW',
    name: 'North-West',
    parent: 'ZA'
  },
  {
    code: 'ZA-WC',
    name: 'Western Cape',
    parent: 'ZA'
  },

Name in two languages without any space between them

Hi,

Hi,

I stumbled upon some names in the 2.js file that I'm not sure if they're 100% correct.
Code 'ES-A' has 'AlicanteAlacant' as a name. That is in fact Alicante (name of the region in Spanish) and Alacant (name of the region in Catalan) joined in a single word. Same happens in 'ES-CS' - 'CastellónCastelló' (Castellón in Spanish and Castelló in Catalan), 'ES-NA' - 'Navarra, Comunidad Foral deNafarroako Foru Komunitatea' (Navarra, Comunidad Foral de in Spanish, Nafarroako Foru Komunitatea in Basque) and 'ES-PV' - 'País VascoEuskal Herria' (País Vasco in Spanish, Euskal Herria in Basque).

While the data is correct for those cases, as both names are official, the representation of the data, joining both without anything that indicates so, seems misleading. I think they'd be better with the local variant indicator, as 'LR-RI', 'MU-CC' and some others.

I'd be happy to do the PR myself but wanted to open the issue first to check that I'm not wrong about that.

Thank you

Spanish subdivisions are in double language with no space/split character

I am looking at the library and caught a possible issue. In Spain some subdivisions have the name in 2 languages. However, the string of the name concatenates the two versions.

Example:

{ code: 'ES-NA', name: 'NavarraNafarroa', parent: true },

This is Navarra in Spanish, and Nafarroa in Basque. But the name is not usable in this way.

Either the object should contain the two languages, or allow a better split. In theory, the iso table contains the language code which would make this much easier.

Shall we consider to refactor the list including the language code?

ISO Org

The ISO codes and the mapping is collected from ISO.org???
Data is as per standards but still there are some extra information that user may need to implement some business logic.
Can someone please confirm?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.