Files
openlayers/examples/min-max-resolution.html
2021-09-18 09:28:25 +02:00

15 lines
660 B
HTML

---
layout: example.html
title: Layer Min/Max Resolution
shortdesc: Show/hide layers depending on current view resolution.
docs: >
<p>Zoom in twice: the MapBox layer should hide and the OSM layer should be shown.</p>
<p>If you continue to zoom in, you'll see the OSM layer also disappear.</p>
<p>The rendering of the layers are here controlled using minResolution and maxResolution options.</p>
tags: "minResolution, maxResolution, resolution"
cloak:
- key: pk.eyJ1IjoiYWhvY2V2YXIiLCJhIjoiY2t0cGdwMHVnMGdlbzMxbDhwazBic2xrNSJ9.WbcTL9uj8JPAsnT9mgb7oQ
value: Your Mapbox access token from https://mapbox.com/ here
---
<div id="map" class="map"></div>