
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
common-geohash-parent
Advanced tools
Functions to get common geohash parent(s) of coordinates or bbox
Class with multiple methods to help you find the common parent geohash from points, geohashes, bounding boxes, polygons or other GeoJSON shapes.
Using npm:
npm i common-geohash-parent
Using yarn:
yarn add common-geohash-parent
In node:
const ParentFinder = require('common-geohash-parent');
const bbox = [-3.944092, 40.241799, -3.261566, 40.779502];
const precision = 5;
const finder = new ParentFinder(precision);
finder.fromBBox(bbox)
.then((parents) => {
// parents is ['ezjp','ezjr','ezjx','ezjn','ezjq','ezjw','ezjj','ezjm','ezjt','ezjh','ezjk','ezjs']
...
});
Array.<string>
Kind: global class
ParentFinder class
ParentGeohashList
Finds common parents from array of points
Kind: instance method of ParentFinder
Returns: ParentGeohashList
- Array of geohashes
Param | Type | Description |
---|---|---|
points | Array.<Array.<number>> | [lon, lat] |
ParentGeohashList
Finds common parents from array of geohashes
Kind: instance method of ParentFinder
Returns: ParentGeohashList
- List of parent geohashes
Param | Type | Description |
---|---|---|
hashes | Array.<string> | List of geohashes |
Promise.<ParentGeohashList>
Finds common parents from bounding box
Kind: instance method of ParentFinder
Returns: Promise.<ParentGeohashList>
- Promise of list of parent geohashes
Param | Type | Description |
---|---|---|
bbox | Array.<number> | [number, number, number, number] |
Promise.<ParentGeohashList>
Finds common parents from polygon feature
Kind: instance method of ParentFinder
Returns: Promise.<ParentGeohashList>
- Promise of list of parent geohashes
Param | Type | Description |
---|---|---|
inputPolygon | object | GeoJSON shape |
Kind: static class of ParentFinder
Creates an instance of ParentFinder.
Param | Type | Description |
---|---|---|
parentPrecision | number | Initial parent precision |
[optimization] | OptimizationOptions | If desired, specify optimization options |
Array.<string>
Kind: global typedef
Properties
Name | Type |
---|---|
enabled | boolean |
maxParents | number |
FAQs
Functions to get common geohash parent(s) of coordinates or bbox
The npm package common-geohash-parent receives a total of 39 weekly downloads. As such, common-geohash-parent popularity was classified as not popular.
We found that common-geohash-parent demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.