I am trying to add layers from this ArcGIS MapServer to my Leaflet webmap:
http://igems.doi.gov/arcgis/rest/services/igems_haz/MapServer
This code added the weather warnings layer (12), but used the default blue symbol for all of the feature types.
var URL2 = 'http://igems.doi.gov/arcgis/rest/services/igems_haz/MapServer/12/'
var warnings = L.esri.featureLayer({
url: URL2,
useCors: false
});
warnings.addTo(weather);
weather.addTo(map);
Looking at this service description page, it seems that there is are preset symbols configured on the server: http://igems.doi.gov/arcgis/rest/services/igems_haz/MapServer/12
From example for an Ash Warning:
Symbol:
Style: esriSFSSolid
Color: [169, 169, 169, 255]
Outline:
Style: esriSLSSolid
Color: [0, 0, 0, 0]
Width: 0
Is there an option for L.esri.featureLayer to use the preset symobology?