I am creating a webmap from JSON using esri utils.createMap. My question is that I have a single layer that actually contains separate information within in, in this case it contains bike paths, hiking trails, sidewalks, etc. The map simply shows them all at once. I was wondering if there was a way to split the individual paths up within the JSON implementation so that they are all there "own" operational layer... here is the code for that layer...
"url": "http://../mymapserver/8",
"visibility": false,
"opcaity": 0.85,
"title": "Trails",
"visibleLayers": 1,
"layerDefinition": {
"minScale": 0
}
Thanks!
Since the setLayerDefinitions did not work for me I found a different solution. I created individual featureLayers using JSON and added them to the map after the initial map creation.
Thanks.