Skip to content
#

turf

Here are 25 public repositories matching this topic...

PizzaBrandon
PizzaBrandon commented Jan 2, 2019

A short (3 point) closed linestring (rare, but does happen) throws an exception in clean-coords due to the code assuming it's a polygon.

Problem occurs due to https://github.com/Turfjs/turf/blob/master/packages/turf-clean-coords/index.ts#L118 assuming the first and last points matching means it's a polygon.

This can also happen with a linestring that is cleaned to < 4 points. Discovered thi

1ec5
1ec5 commented Mar 8, 2019

IndexedCoordinate.distance is documented to be the distance from the start of the line string to the found coordinate:

https://github.com/mapbox/turf-swift/blob/1114acd2e35512586d3917b1c5f12f4d74344fb7/Sources/Turf/LineString.swift#L92-L104

However, LineString.closestCoordinate(to:) sets it to the distance from the input coordinate to the found coordinate:

https://github.com/mapbox/tu

Improve this page

Add a description, image, and links to the turf topic page so that developers can more easily learn about it.

Curate this topic

Add this topic to your repo

To associate your repository with the turf topic, visit your repo's landing page and select "manage topics."

Learn more

You can’t perform that action at this time.