MCPcopy Create free account
hub / github.com/codealong-dev/ride-sharing / decodeGeoHash

Function decodeGeoHash

web/src/utils/geohash.ts:3–9  ·  view source on GitHub ↗
(geohash: string)

Source from the content-addressed store, hash-verified

1import Geohash from 'latlon-geohash';
2
3export function decodeGeoHash(geohash: string) {
4 const bounds = Geohash.bounds(geohash);
5 return {
6 latitude: [bounds.sw.lat, bounds.ne.lat],
7 longitude: [bounds.sw.lon, bounds.ne.lon],
8 };
9}
10
11// Function to create grid bounds from geohash
12export const getGeohashBounds = (geohash: string) => {

Callers 1

getGeohashBoundsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected