Returns the distance of point to the nearest point on line.
point
line
const d = Lines.distance(line, {x:10,y:10}); Copy
const d = Lines.distance(line, {x:10,y:10});
If an array of lines is provided, the shortest distance is returned.
Line (or array of lines)
Point to check against
Distance
Returns the distance of
point
to the nearest point online
.If an array of lines is provided, the shortest distance is returned.