You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
pointA gets snapped onto a point on the northern line while pointB gets snapped onto a point on the southern line of the multiLineString. Both snapped points are located approximately 150 meters from the respective line start. However, while the location property of nearestToA has the expected value (150.293316294307), the location property of nearestToB is unexpectedly big (389.9028953092881). Apparently, turf has added the full length of the northern line to it which is not what I want.
With the current behavior, there is no easy way to know the location of the nearestToB point along the southern line (which should be a value around 150). Please consider to add an extra property for this (maybe you could call it multiFeatureLocation) or add an option that allows the user to choose which behavior they want.
The text was updated successfully, but these errors were encountered:
turf 7.1.0
Consider the following example:
Expand for GeoJSON FeatureCollection of all the above
pointA
gets snapped onto a point on the northern line whilepointB
gets snapped onto a point on the southern line of themultiLineString
. Both snapped points are located approximately 150 meters from the respective line start. However, while thelocation
property ofnearestToA
has the expected value (150.293316294307
), thelocation
property ofnearestToB
is unexpectedly big (389.9028953092881
). Apparently, turf has added the full length of the northern line to it which is not what I want.With the current behavior, there is no easy way to know the location of the
nearestToB
point along the southern line (which should be a value around150
). Please consider to add an extra property for this (maybe you could call itmultiFeatureLocation
) or add an option that allows the user to choose which behavior they want.The text was updated successfully, but these errors were encountered: