Skip to content

Find Slippy Map / XYZ Tiles that cover a GeoJSON Feature.

Notifications You must be signed in to change notification settings

bencevans/xyz-intersect

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@bencevans/xyz-intersect

Find Slippy Map / XYZ Tiles that cover a GeoJSON Feature.

Example

> const findTiles = require('@bencevans/xyz-intersect')

> const zoom = 10

> findTiles.fromPoint(geojsonPointFeature, zoom)
[ 510, 340 ]

> findTiles.fromPolygon(geojsonPolygonFeature, zoom)
[ [ 32680, 21784 ], [ 32681, 21784 ], [ 32682, 21784 ] ]

> findTiles.toGeoJSON(
    findTiles.fromPolygon(geojsonPolygonFeature, zoom)
  )
# Outputs GeoJSON representation of each of the tiles.

Licence

GPL-3.0

About

Find Slippy Map / XYZ Tiles that cover a GeoJSON Feature.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published