0.2.1 • Published 10 years ago

whichway v0.2.1

Weekly downloads
1
License
-
Repository
-
Last release
10 years ago

Whichway Build Status

Whichway is a small JavaScript library for working out the bearing between 2 locations.

var location1 = {
    lng: 151.187142,
    lat: -33.907319
};
var location2 = {
    lng: 151.196117,
    lat: -33.907319
};

var myBearing = new Whichway(location1, location2).getBearing();

You can also get the distance between 2 locations in kilometres

var myDistance = new Whichway(location1, location2).getDistance();