I am trying to convert the selected regions in the following URL (marked in red) into geojson and retrieve administrative info (State, Country etc.)
https://esri.github.io/esri-leaflet/examples/spatial-queries.html
This is an example code that I found online.
var feature = L.esri.Util.arcgisToGeoJSON(neighborhoods[i], ids[i]);
var latlng = L.Projection.Mercator.unproject(L.point(feature.geometry.coordinates));
feature.geometry.coordinates = [latlng.lng, latlng.lat];
Please Help!