vue-leaflet/Vue2Leaflet

LTileLayer do not support subdomains with serveral letters (but leaflet do)

Closed this issue · 1 comments

Description

subdomains in LTileLayer are not fully compatible with leaflet.
In leaflet, subdomains can be a string where each letter is used sequentially or an array of strings where each strings is used sequentially. see here:
https://leafletjs.com/reference-1.6.0.html#tilelayer-subdomains

With the current implementation Vue2Leaflet do not support map tiles where alternate server is located at a multi-letter subdomains as arcgisonline.com

Live Demo

http://jsfiddle.net/4jbLcer6/2/

Steps to Reproduce

      <l-tile-layer
        :url="https://{s}.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer/tile/{z}/{y}/{x}"
        :name="anything"
        :attribution="anywho"
        :subdomains="["server", "services"]"
      />

Expected Results

No error is throw, and the tiles are loaded from subdomains with multi-letter adress.

Actual Results

[Vue warn]: Invalid prop: type check failed for prop "subdomains". Expected String with value "server", got Array 

found in

---> <LTileLayer>
       <LMap>

Browsers Affected

  • [ x ] Chrome
  • [ x ] Firefox
  • Edge
  • Safari 9
  • Safari 8
  • IE 11

Versions

  • Leaflet: v1.6.0
  • Vue: v2.6.11
  • Vue2Leaflet: v2.5.2

@elmatou Thank you for reporting this! Labeled the issue accordingly. This is up for grab, or I will get to it somewhere next week!