I have an Angular map app with a WMS layer initialized as following:
this.layer =
new ImageLayer({
source: new ImageWMS({
url: url,
params: {LAYERS: this.getActiveLayers()},
projection: proj
})
});
this.map = new Map({
target: 'map',
layers: [this.layer],
view: new View({
projection: proj
})
});
At some point I need to update the wms layer, so I create another ImageWMS
with the new requirements
this.auxLayer =
new ImageLayer({
source: new ImageWMS({
url: url,
params: {LAYERS: this.newLayers()},
projection: proj
})
});
How can I update the layer
with the new auxLayer
info?