UNPKG

leaflet-plugins

Version:

Miscellaneous plugins for Leaflet library for services that need to display route information and need satellite imagery from different providers

30 lines (25 loc) 704 B
<html> <head> <title>L.Yandex LoadApi (addon) deferred example</title> <link rel="stylesheet" href="https://unpkg.com/leaflet@1.5.1/dist/leaflet.css" /> <script src="https://unpkg.com/leaflet@1.5.1/dist/leaflet.js"></script> <script src="../layer/tile/Yandex.js"></script> <script src="../layer/tile/Yandex.addon.LoadApi.js"></script> </head> <body> <div style="width:100%; height:100%" id="map"></div> <script> var map = L.map('map', { center: [67.6755, 33.936], zoom: 10, attributionControl: false }); L.control.layers({ '(deferred) Yandex': L.yandex({ apiParams: '<your API-key>' }), '(deferred) Yandex Hybrid': L.yandex('hybrid') }).addTo(map); </script> </body> </html>