All Projects → Leaflet → Leaflet.vectorgrid

Leaflet / Leaflet.vectorgrid

Display gridded vector data (sliced GeoJSON or protobuf vector tiles) in Leaflet 1.0.0

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Leaflet.vectorgrid

leaflet-geojson-selector
Show GeoJSON Layer like as Interactive Menu List
Stars: ✭ 88 (-79.82%)
Mutual labels:  vector-tiles, geojson, leaflet
Kepler
The open source full-stack geosocial network platform
Stars: ✭ 125 (-71.33%)
Mutual labels:  geojson, leaflet
Leaflet Elevation
Leaflet plugin that allows to add elevation profiles using d3js
Stars: ✭ 88 (-79.82%)
Mutual labels:  geojson, leaflet
Vector Datasource
Tilezen vector tile service - OpenStreetMap data in several formats
Stars: ✭ 427 (-2.06%)
Mutual labels:  geojson, vector-tiles
Ngx Leaflet Starter
A soup of Angular and Leaflet
Stars: ✭ 208 (-52.29%)
Mutual labels:  vector-tiles, leaflet
Mapbox Gl Js
Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL
Stars: ✭ 8,017 (+1738.76%)
Mutual labels:  geojson, vector-tiles
Mapbox Gl Native Android
Interactive, thoroughly customizable maps in native Android powered by vector tiles and OpenGL
Stars: ✭ 135 (-69.04%)
Mutual labels:  geojson, vector-tiles
Tiler
A no nonsense Vector Tile pipeline
Stars: ✭ 132 (-69.72%)
Mutual labels:  geojson, vector-tiles
Mapstore2
Modern webmapping with OpenLayers, Leaflet and React
Stars: ✭ 251 (-42.43%)
Mutual labels:  geojson, leaflet
echarty
Minimal R/Shiny Interface to ECharts.js
Stars: ✭ 49 (-88.76%)
Mutual labels:  geojson, leaflet
vaguely-rude-places
The map of Vaguely Rude Place Names
Stars: ✭ 19 (-95.64%)
Mutual labels:  geojson, leaflet
Tangram
WebGL map rendering engine for creative cartography
Stars: ✭ 1,964 (+350.46%)
Mutual labels:  vector-tiles, leaflet
Node Tileserver
A lightweight tileserver based on NodeJS for serving bitmap and vector tiles.
Stars: ✭ 148 (-66.06%)
Mutual labels:  vector-tiles, leaflet
Leaflet Geoman
🍂🗺️ The most powerful leaflet plugin for drawing and editing geometry layers
Stars: ✭ 1,088 (+149.54%)
Mutual labels:  geojson, leaflet
Tippecanoe
Build vector tilesets from large collections of GeoJSON features.
Stars: ✭ 1,986 (+355.5%)
Mutual labels:  geojson, vector-tiles
Leaflet.timeline
Display arbitrary GeoJSON on a map with a timeline slider and play button
Stars: ✭ 291 (-33.26%)
Mutual labels:  geojson, leaflet
Mapbox Gl Native
Interactive, thoroughly customizable maps in native Android, iOS, macOS, Node.js, and Qt applications, powered by vector tiles and OpenGL
Stars: ✭ 4,091 (+838.3%)
Mutual labels:  geojson, vector-tiles
Offlinemap
基于MySQL + Node.js + Leaflet的离线地图展示,支持百度、谷歌、高德、腾讯地图
Stars: ✭ 343 (-21.33%)
Mutual labels:  leaflet
Vectiler
A vector tile, terrain and city 3d model builder and exporter
Stars: ✭ 394 (-9.63%)
Mutual labels:  vector-tiles
Gdal2tiles Leaflet
Generate raster image tiles for use with leaflet.
Stars: ✭ 338 (-22.48%)
Mutual labels:  leaflet

Leaflet.VectorGrid

Display gridded vector data (sliced GeoJSON, TopoJSON or protobuf vector tiles) in Leaflet 1.0.0

Demos

demo-geojson.html Sliced GeoJSON
demo-topojson.html Sliced TopoJSON (sorry for the antimeridian mess, topojson-to-geojson seems to not handle it properly)
demo-vectortiles.html Protobuf vector tiles: OpenMapTiles, MapBox, MapZen or even ESRI vector tiles
demo-points.html Clickable points and lines
demo-points-icons.html Points as icons

Using

If you use npm:

	npm install leaflet.vectorgrid

That will make available two files: dist/Leaflet.VectorGrid.js and dist/Leaflet.VectorGrid.bundled.js.

The difference is that dist/Leaflet.VectorGrid.bundled.js includes all of VectorGrid's dependencies:

If you are adding these dependencies by yourself, use dist/Leaflet.VectorGrid.js instead.

If you don't want to deal with npm and local files, you can use unpkg.com instead:

<script src="https://unpkg.com/[email protected]/dist/Leaflet.VectorGrid.bundled.js"></script>

or, with the same caveats about bundled dependencies:

<script src="https://unpkg.com/[email protected]/dist/Leaflet.VectorGrid.js"></script>

Docs

This plugin exposes two new classes:

  • L.VectorGrid.Slicer for displaying GeoJSON or TopoJSON data
  • L.VectorGrid.Protobuf for displaying vector tiles from an online tile server

You can find the API documentation, and the explanation about the styling, at:

https://leaflet.github.io/Leaflet.VectorGrid/vectorgrid-api-docs.html

Dependencies

L.VectorGrid.Slicer requires geojson-vt: the global variable geojsonvt must exist. If topojson data is used, then the topojson global variable must also exist.

L.VectorGrid.Protobuf requires vector-tile and pbf: the global variables VectorTile and Pbf must exist.

By default, VectorGrid is built with those dependencies bundled.

Developing

Run npm install.

TODO

  • Sub-panes for the tile renderers (to set the "z-index" of layers/features)
  • More <g>roups in SVG
  • Offscreen <canvas>es in Canvas
  • getBounds() support for the slicer (inherit/extrapolate from geojson data)
  • Parser for mapbox-like vector stylesheets

Motivation

Before VectorGrid, loading vector tiles in Leaflet could only be done with the Leaflet.MapboxVectorTile or the Hoverboard plugin, but neither of those works with Leaflet 1.0.0 (or greater).

VectorGrid leverages the GridLayer feature introduced in Leaflet 1.0.0.

Legalese


"THE BEER-WARE LICENSE": [email protected] wrote this file. As long as you retain this notice you can do whatever you want with this stuff. If we meet some day, and you think this stuff is worth it, you can buy me a beer in return.


Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].