turf-point
Creates a geojson Point Feature based on an x and y coordinate. Properties can be added optionally.
###Install
npm install turf-point
###Parameters
name | description |
---|
x | x coordinate |
y | y coordinate |
###Usage
point(x, y)
###Example
var point = require('turf-point')
var pt1 = point(-75.343, 39.984)
var pt2 = point(-75.343, 39.984, {name: 'point 1', population: 5000})
console.log(pt1)
console.log(pt2)
###CLI
npm install turf-point -g
turf-point 2 1
turf-point --lat 1 --lon 2
turf-point --latitude 1 --longitude 2
turf-point -x 2 -y 1