show

Shows the layer, if not visible.

<button class="k-button k-button-lg k-button-solid-primary" id="show">Show Layer</button>
<div id="map"></div>
<script>
  $("#show").on("click", function() {
    let map = $("#map").data("kendoMap");
    let layer = map.layers[0];

    // Show the first layer of the map
    layer.show();
  });

  function createMap() {
    $("#map").kendoMap({
      center: [45, 45],
      minZoom: 3,
      zoom: 4,
      wraparound: false,
      layers: [
        {
          type: "tile",
          urlTemplate: "https://#= subdomain #.tile.openstreetmap.org/#= zoom #/#= x #/#= y #.png",
          subdomains: ["a", "b", "c"],
          attribution: "&copy; <a href='https://osm.org/copyright'>OpenStreetMap contributors</a>"
        }
      ]
    });

    // Hide the first layer by default.
    $("#map").data("kendoMap").layers[0].hide();
  }

  $(document).ready(createMap);
</script>
In this article