Closed DenisCarriere closed 7 years ago
Did you npm update
to use the newest version of geojson-polygon-self-intersections
? As mentioned in #7, this should fix your issue!
🤔 I don't get it.. why would I need to npm update
? Why wouldn't you update your dependencies directly in your module?
Still no change... Even hardcoded the dependencies to the specific latest versions:
"dependencies": {
"geojson-polygon-self-intersections": "1.1.2",
"simplepolygon": "1.2.0"
}
We've added it to your local tests, same results.
https://github.com/mclaeysb/simplepolygon/blob/master/test/out/complex.geojson
If my understanding is correct, npm update
will update all dependancies, including geojson-polygon-self-intersections
to 1.1.2. Just pushed simplepolygon again te make sure it's requiring it.
test/in/complex.geojson
seems to give correct results here. Not sure why you're getting something else. How could we find out?
Oops 🤓 Yea I thought it was only returning 2 features, but that's because the output color ramp only had two colors.
👍 Works
Handling these kinds of "complex" shapes can be a mess, I wouldn't want to attempt doing this, thanks for help & contributions to this module!
Great! Glad I could be of help. Congrats with the turf release btw!
Thanks! 👍 Things tend to blow up every time we push a big release, lol that's why I noticed your library changed.
Any chance that simplepolygon
will support MultiPolygon?
We've got flattenEach
that can help with that.
Also noticed you might be another user of this newly proposed ringEach
feature in @turf/meta
(from @rowanwins ).
Thanks for pointing this out. I don't currently have plans to develop simplepolygon
further. Will let you know when that's the case, and take a look at these then!
👍 No worries, I know it's a lot of work :) If ever you do, check out those new Turf features.
Just noticed some positive changes in
v1.2.0
.Still not 100% there yet, but better than before, only splits 1 geometry.
Using this
complex.geojson
Before to
v1.2.0
Now
v1.2.0