digidem / leaflet-bing-layer

Bing Maps Layer for Leaflet v1.0.0
http://digidem.github.io/leaflet-bing-layer/
87 stars 53 forks source link

Does leaflet-bing-layer support the usage of Bing Maps v8? #20

Closed jengeb closed 7 years ago

jengeb commented 7 years ago

In the index.js file you can find a variable called statics.METADATA_URL that points to the Bing Maps script of version 1:

statics: {
    METADATA_URL: 'https://dev.virtualearth.net/REST/v1/Imagery/Metadata/{imagerySet}?key={bingMapsKey}&include=ImageryProviders&uriScheme=https',
    POINT_METADATA_URL: 'https://dev.virtualearth.net/REST/v1/Imagery/Metadata/{imagerySet}/{lat},{lng}?zl={z}&key={bingMapsKey}&uriScheme=https'
  }

I suppose I can overwrite this url and use a newer version, right? Does leaflet-bing-layer support the usage of Bing Maps version 8? I ask because the embedding of the v8 script is described in this migration guide and different (e.g., asynchronous) from older versions:

<script type='text/javascript' src='http//www.bing.com/api/maps/mapcontrol?callback=GetMap' async defer></script>