GeoCoder Client Library for Node.js
This module provides basic geo coding methods. It contains method for calculating distance between the points and checking if distance falls in the rance of point
Example
ES5 way
const GeoCoder = ;const coder = 'M'const latitude: lat2 longitude: lon2 = testData0const geoObj = lat1: 53339428 lon1: -6257664 lat2: 52986375 lon2: -6043701const distance = coder
ES6 way
;const coder = 'M'const geoObj = lat1: 53339428 lon1: -6257664 lat2: 52986375 lon2: -6043701const distance = coder
Installation
npm install geocoder_node //install locally
npm install -g geocoder_node //install globally
npm install geocoder_node --save //install locally and save to package json
Quick Start
Methods supported
Get distance between points based on unit
const distance = coder;
Get absolute distance between points
const distance = coder;
Convert to given unit
const distance = coder;
check if points have distance in the range of input
const distance = coder;
Tests
To run tests type npm test. To run tests with coverage type npm coverage.
Contributors
Originally authored by @princesoni1989
LICENSE
geocoder_node is released under the ISC License Copyright (c) 2019 Prince Soni
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.