I added a WMTS Layer to a Leaflet map. The tiles are loading but aren't in the correct order. Has anyone ever encountered this problem? If so, how did you overcome it?
var map = new L.Map('viewerDiv', {
crs: L.CRS.EPSG3857
});
var url =
'http://services.arcgisonline.com/arcgis/rest/services/World_Topo_Map/MapServer/WMTS/tile/1.0.0/World_Topo_Map/default/default028mm/{z}/{x}/{y}.png';
var tilelayer = new L.tileLayer(url, {
tileSize: 256,
tms: true,
attribution: 'World Map'
});
map.addLayer(tilelayer);
map.setView(L.latLng(50, 8), 4);