1

I am currently working with Leaflet.js and Overpass API and I am using osmtogeojson to do the format change between the OSM-JSON that Overpass API outputs and the GeoJSON that Leaflet.js needs as input. To do so I am using the following code:

data = osmtogeojson(osm_data);

This works perfectly.

Here comes the problem: I am trying to ignore some data that I am getting on the OSM-JSON dataset. So I am trying to use uninterestingTags as given in the osmtogeojson API. The thing is that I don't know how to code this thing. This is not working:

 data = osmtogeojson(
      osm_data, uninterestingTags = {"source"}
 );
0

1 Answer 1

2

Try setting the tag to true, as done here:

uninterestingTags = {"source": true}.

1
  • 2
    This seems to be working. Warning: It only ignores unconnected nodes. If the node is part of a way, it's taken anyways (otherwise, most ways would be void as most of their nodes have no tags).
    – deiviz
    Commented Sep 26, 2014 at 9:26

Not the answer you're looking for? Browse other questions tagged or ask your own question.