Content-Length: 285740 | pFad | http://github.com/stepankuzmin/h3-polyfill

90 GitHub - stepankuzmin/h3-polyfill: Uber h3 polyfill CLI
Skip to content

stepankuzmin/h3-polyfill

Repository files navigation

h3-polyfill

Build Status

h3-polyfill is a library and a command line interface to Uber h3 polyfill.

It takes an input polygon as a GeoJSON file and outputs hex as a GeoJSON polygon feature collection.

screenshot

Installation

npm i h3-polyfill

Usage

const h3Polyfill = require("h3-polyfill");

const polygon = {
  type: "Feature",
  properties: {},
  geometry: {
    type: "Polygon",
    coordinates: [
      [
        [-122.40898669999721, 37.81331899998324],
        [-122.35447369999936, 37.71980619999785],
        [-122.4798767000009, 37.815157199999845],
        [-122.40898669999721, 37.81331899998324]
      ]
    ]
  }
};

const hex = h3Polyfill(polygon, 7);

CLI Usage

Usage: h3-polyfill <polygon.geojson> <resolution>

Example:

npx h3-polyfill polygon.geojson 7 > hex.geojson








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/stepankuzmin/h3-polyfill

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy