3.0.3 • Published 4 years ago

@caeser1996/haversine v3.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

@caeser1996/haversine

npm (scoped) npm bundle size (minified)

Calculate distance between Two Coordinates using haversine.

Install

$ npm install @caeser1996/haversine

Usage

const haversine = require("@caeser1996/haversine");


let coords1=[24.20,32.20] //[long,lat]
let coords2 =[32.20,45.20]//[long,lat]


haversine(coords1,coords2,false);//false if you want it in kms

1601.612304937011