Skip to content

Commit

Permalink
Merge pull request #23 from uber/release-1.2
Browse files Browse the repository at this point in the history
Prepare for release 1.2
  • Loading branch information
nrabinowitz authored Sep 8, 2021
2 parents 6b8b472 + 765e978 commit e6c5144
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const feature = geojson2h3.h3SetToFeature(hexagons);
## geojson2h3

* [geojson2h3](#module_geojson2h3)
* [.featureToH3Set(feature, resolution)](#module_geojson2h3.featureToH3Set) ⇒ <code>Array.&lt;String&gt;</code>
* [.featureToH3Set(feature, resolution, [options])](#module_geojson2h3.featureToH3Set) ⇒ <code>Array.&lt;String&gt;</code>
* [.h3ToFeature(hexAddress, [properties])](#module_geojson2h3.h3ToFeature) ⇒ <code>Feature</code>
* [.h3SetToFeature(hexagons, [properties])](#module_geojson2h3.h3SetToFeature) ⇒ <code>Feature</code>
* [.h3SetToMultiPolygonFeature(hexagons, [properties])](#module_geojson2h3.h3SetToMultiPolygonFeature) ⇒ <code>Feature</code>
Expand All @@ -62,7 +62,7 @@ const feature = geojson2h3.h3SetToFeature(hexagons);

<a name="module_geojson2h3.featureToH3Set"></a>

### geojson2h3.featureToH3Set(feature, resolution) ⇒ <code>Array.&lt;String&gt;</code>
### geojson2h3.featureToH3Set(feature, resolution, [options]) ⇒ <code>Array.&lt;String&gt;</code>
Convert a GeoJSON feature to a set of hexagons. *Only hexagons whose centers
fall within the feature will be included.* Note that conversion from GeoJSON
is lossy; the resulting hexagon set only approximately describes the original
Expand All @@ -82,6 +82,7 @@ the `ensureOutput` option.
| --- | --- | --- |
| feature | <code>Object</code> | Input GeoJSON: type must be either `Feature` or `FeatureCollection`, and geometry type must be either `Polygon` or `MultiPolygon` |
| resolution | <code>Number</code> | Resolution of hexagons, between 0 and 15 |
| [options] | <code>Object</code> | Options |
| [options.ensureOutput] | <code>Boolean</code> | Whether to ensure that at least one cell is returned in the set |


Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "geojson2h3",
"description": "Conversion utilities between H3 indexes and GeoJSON",
"version": "1.1.1",
"version": "1.2.0",
"author": "Nick Rabinowitz <[email protected]>",
"keywords": [
"h3",
Expand Down
1 change: 1 addition & 0 deletions src/geojson2h3.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ function featureCollectionToH3Set(featureCollection, resolution) {
* `FeatureCollection`, and geometry type must be
* either `Polygon` or `MultiPolygon`
* @param {Number} resolution Resolution of hexagons, between 0 and 15
* @param {Object} [options] Options
* @param {Boolean} [options.ensureOutput] Whether to ensure that at least one
* cell is returned in the set
* @return {String[]} H3 indexes
Expand Down

0 comments on commit e6c5144

Please sign in to comment.