The site I have has about 100 layers, all coming from different map services. I'm adding the layers like so..
var layer = new MapImageLayer({
url: "[map service url]",
imageFormat: "png32",
sublayers: [{
id: "[id of the map service layer]"
visible: false,
source: {
type: "map-layer",
mapLayerId: "[id of the map service layer]"
}
}]
})
layer.id = "[unique id number]"
mapLayers.push(layer);
Is there some type of limit on how many MapImageLayer I can load? It gets very slow just doing basic panning. I did the same thing in v 3.x and never had a performance issue.
Attached is a performance profile from Chrome Dev Tools. You will notice that ESRI's JS API is dropping frames when painting the map to the screen.
Any help would be appreciated.