0

Expected Result on Map enter image description here

import * as L from "leaflet";
import * as esri from  "esri-leaflet"
import "esri-leaflet-renderers";

let _layer = esri.featureLayer({
url: 'https://services.arcgis.com/aA3snZwJfFkVyDuP/ArcGIS/rest/services/airport_districts_and_spheres/FeatureServer/1',
simplifyFactor: 1
});
this.map.addLayer(_layer);

Since Esri-leaflet-renderer does not support "symbol-type: esriPFS", is there any way we can render esriPFS (Picture Filled Symbol) on leaflet map?

vinita jain
  • 163
  • 2
  • 18
  • I just gave it a try and it shows a polygon. what do you expect to show? – kboul Mar 18 '21 at 08:08
  • Is it showing image? I have attached an expected rendered image above. – vinita jain Mar 18 '21 at 15:32
  • No, you are right. Only the polygon. – kboul Mar 18 '21 at 15:58
  • 1
    This is a good question, especially in light of the fact that esri-leaflet just upgraded to v3, as did a lot of its official esri plugin (geosearch, vectortiles, etc.). I don't see that the esri-leaflet-renderers package updated though, but I would open an issue on their GH asking if they're going to update it for the new esri-leaflet 3 release, and if that update might bring in support for advanced fill types. In the meantime, your fill pattern looks simple - a bunch of green dots. You may be able to reproduce this manually with [leaflet-pattern](https://github.com/teastman/Leaflet.pattern) – Seth Lutske Mar 18 '21 at 16:48
  • Thanks @SethLutske, Appreciate your help. To use leaflet-pattern I need to pass the options which are not available for PFS symbol of FeatureServer renderer object. Need a some other solution to render picture filled symbol. – vinita jain Mar 18 '21 at 22:49
  • I meant more that you would have to code the pattern again from scratch - a bunch of small green circles shouldn't be too hard to accomlish with leaflet-pattern. You wouldn't be reading from the FeatureServerm, you'd just be mimicing the renderer from scratch – Seth Lutske Mar 18 '21 at 23:09

0 Answers0