geo-area

1.0.0 • Public • Published

geo-area

npm version

convex hull 2D algorithm using monotone chain algorithm

usage

const geoarea = require('geo-area')(/*options*/{x: 'lng', y: 'lat'});
 
const polygon = [
  {
    lng: 121.409058,
    lat: 31.191149
  },
  ...
];
 
let area = geoarea(polygon);
 

Options

option desc default
x property key x 'longitude'
y property key y 'latitude'

Readme

Keywords

Package Sidebar

Install

npm i geo-area

Weekly Downloads

302

Version

1.0.0

License

MIT

Last publish

Collaborators

  • eatgrass