Calculate distance and bearing between two Latitude/Longitude points using Haversine formula in JavaScript

Google Author link