forked from MapComplete/MapComplete
Add custom javascript snippets to calculate tags
This commit is contained in:
parent
3e130ebe80
commit
f124d9ded7
17 changed files with 799 additions and 14649 deletions
|
@ -21,6 +21,15 @@ export class GeoOperations {
|
|||
return coordinates;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the distance between the two points in kilometers
|
||||
* @param lonlat0
|
||||
* @param lonlat1
|
||||
*/
|
||||
static distanceBetween(lonlat0: [number,number], lonlat1:[number, number]){
|
||||
return turf.distance(lonlat0, lonlat1)
|
||||
}
|
||||
|
||||
static featureIsContainedInAny(feature: any,
|
||||
shouldNotContain: any[],
|
||||
maxOverlapPercentage: number): boolean {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue