0.3.2 • Published 2 months ago

react-leaflet-vector-tile-layer v0.3.2

Weekly downloads
-
License
MIT
Repository
github
Last release
2 months ago

react-leaflet-vector-tile-layer

Vector tile layer for React Leaflet V3. This is a wrapper around @maplibre/maplibre-gl-leaflet. Tested with both Mapbox, Maptiler and self hosted vector tiles.

Vector tile layer can be nested inside React Leaflet Layers Control.

Mapbox

import { MapContainer } from "react-leaflet";
import "leaflet/dist/leaflet.css";
import VectorTileLayer from "react-leaflet-vector-tile-layer";

function App() {
  return (
    <MapContainer center={[50.5, 30.5]} zoom={3} style={{ height: "100vh" }}>
      <VectorTileLayer
        styleUrl="mapbox://styles/customstyles/ckpslkwor05q318mzmetjbv5z"
        accessToken="XXXX"
      />
    </MapContainer>
  );
}

export default App;

Maptiler

import { MapContainer } from "react-leaflet";
import "leaflet/dist/leaflet.css";
import VectorTileLayer from "react-leaflet-vector-tile-layer";

function App() {
  return (
    <MapContainer center={[50.5, 30.5]} zoom={3} style={{ height: "100vh" }}>
      <VectorTileLayer
        styleUrl="https://demotiles.maplibre.org/style.json"
      />
    </MapContainer>
  );
}

export default App;

Sponsors

shademap.app - Year-round world map of sun and shadow

0.3.0

2 months ago

0.3.2

2 months ago

0.3.1

2 months ago

0.2.1

4 months ago

0.2.0

1 year ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago

0.1.0

6 years ago