Comments (3)
Weird, yeah I don't really understand it.
I do know that "Metropolitan France" with the ISO code FX
, and is a separate feature that is within France and within Europe, EU, etc..
https://ideditor.codes/?code=Q212429
"groups": ["FR", "155", "150", "EU", "UN", "001"],
from country-coder.
I did some more testing today and I still don't know what's going on
> import("@ideditor/country-coder").then(module => { cc = module });
Promise { <pending> }
> cc.isInEuropeanUnion('fx')
true
> cc.isInEuropeanUnion('fr')
false
> cc.isInEuropeanUnion('es')
true
I don't see any obvious difference in the data in how Spain and France are different. Both are made up of "parent" features with null
geometry and "child" features with groups
properties.
from country-coder.
Update: I noticed a few interesting facts in the borders.json data file:
Neither spain nor france are directly listed as members of the EU.
all of Spain's territories are listed as having EU group membership, even though Spain itself does not.
None of France's territories are listed as having EU group membership. France itself, like spain, is also not listed as a direct EU member.
So why the difference?
If I modify all of France's territories to also be members of the EU, then the test starts to pass. Somehow, group membership is being synthesized from the 'ground up', considering constituent territories first.
from country-coder.
Related Issues (20)
- Reduce package/bundle size - dynamically import borders.json HOT 1
- FeedBack - Code HOT 1
- Northen Cyprus' ISO code HOT 2
- ISO 3166 of countries with Sovereign states HOT 1
- Emoji flag for Metropolitan France is broken HOT 3
- A few more sub-country pseudo codes HOT 3
- Africa is a donut
- New release? HOT 5
- Chukchi Peninsula shows as being in Europe instead of Asia
- Support bbox query? HOT 2
- [wrong repo]
- Sub-regions, repeated data and .geojson hosting HOT 1
- United Kingdom HOT 12
- We might be using "exports" wrong HOT 2
- ESM export broken in react-native 0.64.2 (non-expo) HOT 4
- File extension pattern matching in React Native 0.62.4 for mjs cjs main and module files HOT 4
- Fully ESM compatible ?
- Don't use for..in to iterate over arrays
- Missing triangle on Swiss border HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from country-coder.