0

I have an interactive map built with react-leaflet on which I want to render two vector tile layers, one of them renders points and the other renders polygons. The tiles are served by my own backend under the zoom, x, y coordinates system (zxy) and my URL is something similar to https://example.com/.../tiles/{z}/{x}/{y}

The problem is I have not been able to render the layers at all.

My knowledge on React and leaflet is very limited, so the only thing I tried so far is to use a standard TileLayer:

<TileLayer
    attribution='me'
    url="http://localhost:8000/api/v3/polygon-tiles/{z}/{x}/{y}"
    maxZoom={20}
    minZoom={15}
/>

As far as my understanding goes, this doesn't work because the TileLayer component only works when rendering image based tiles, not vectors.

Jose
  • 1
  • Looks like you will need to create your own implementation or use a plugin for it https://stackoverflow.com/questions/70822077/how-to-use-ordance-survey-vector-tiles-with-react-leaflet – Disco Dec 01 '22 at 09:48

0 Answers0