Giter Site home page Giter Site logo

Keep geojson properties about topojson HOT 6 CLOSED

kvalev avatar kvalev commented on July 3, 2024
Keep geojson properties

from topojson.

Comments (6)

Dave-Evans avatar Dave-Evans commented on July 3, 2024 2

I noticed this as well. For what it's worth, I was able to keep the properties when converting to Topology from a GeoDataFrame.

from topojson.

mattijn avatar mattijn commented on July 3, 2024

Hm, I think it should be copied over, can you please provide a small reproducible example including the data?

from topojson.

sheep-queen avatar sheep-queen commented on July 3, 2024

missing_properties
Hello, I'm having this issue as well. Note that when I copy and paste the code for input data of type "FeatureCollection or Features", the following is the JSON that is returned. Note that unlike the example response provided, this does not include the "properties": {"name": "abc"} attribute.
{
"type": "Topology",
"objects": {
"data": {
"geometries": [
{"type": "Polygon", "arcs": [[-2, 0]]},
{"type": "Polygon", "arcs": [[1, 2]]}
],
"type": "GeometryCollection"
}
},
"bbox": [0.0, 0.0, 2.0, 1.0],
"arcs": [
[[1.0, 0.0], [0.0, 0.0], [0.0, 1.0], [1.0, 1.0]], [[1.0, 0.0], [1.0, 1.0]],
[[1.0, 1.0], [2.0, 1.0], [2.0, 0.0], [1.0, 0.0]]
]
}

from topojson.

mattijn avatar mattijn commented on July 3, 2024

Thanks for re-raising the issue @sheep-queen! Including an example. I can reproduce it with both shapely 1.7.1 and 1.8. Not sure what is going on.

from topojson.

sheep-queen avatar sheep-queen commented on July 3, 2024

I noticed this as well. For what it's worth, I was able to keep the properties when converting to Topology from a GeoDataFrame.

Thanks @Dave-Evans! That works for me too - convert my shapefile to GeoDataFrame then run topology and output as TopoJSON.

from topojson.

mattijn avatar mattijn commented on July 3, 2024

Issue is fixed by #154

from topojson.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.