4.7.3 • Published 9 years ago

@turf/line-distance v4.7.3

Weekly downloads
5,074
License
MIT
Repository
github
Last release
9 years ago

@turf/line-distance

lineDistance

Takes a GeoJSON and measures its length in the specified units, Point's distance are ignored.

Parameters

Examples

var line = turf.lineString([[115, -32], [131, -22], [143, -25], [150, -34]]);
var length = turf.lineDistance(line, 'miles');

//addToMap
var addToMap = [line];
line.properties.distance = length;

Returns number length of GeoJSON


This module is part of the Turfjs project, an open source module collection dedicated to geographic algorithms. It is maintained in the Turfjs/turf repository, where you can create PRs and issues.

Installation

Install this module individually:

$ npm install @turf/line-distance

Or install the Turf module that includes it as a function:

$ npm install @turf/turf
4.7.3

9 years ago

4.7.1

9 years ago

4.7.0

9 years ago

4.6.0

9 years ago

4.5.2

9 years ago

4.5.1

9 years ago

4.4.0

9 years ago

4.3.0

9 years ago

4.2.0

9 years ago

4.1.0

9 years ago

4.0.2

9 years ago

4.0.1

9 years ago

4.0.0

9 years ago

3.14.2

9 years ago

3.14.0

9 years ago

3.13.0

9 years ago

3.10.5

9 years ago

3.10.3

9 years ago

3.10.0

9 years ago

3.7.5

9 years ago

3.7.3

9 years ago

3.7.2

9 years ago

3.7.0

10 years ago

3.6.3

10 years ago

3.6.1

10 years ago

3.5.3

10 years ago

3.5.2

10 years ago

3.3.3

10 years ago

3.1.1

10 years ago

3.0.16

10 years ago

3.0.15

10 years ago