Hi everyone,
I wonder if there is a solution to convert an edited map (geo Json file) to topology (topoJson)
I tried this toolhttps://mapshaper.org/ but the exported topolgy doesn't work, GeoJson works fine.
There is no official tool to convert GeoJSON/TopoJSON files. You can find lots of tools of that kind on the internet, e.g. you can use tools from this package https://github.com/topojson and convert files from GeoJSON to TopoJSON using e.g. https://github.com/topojson/topojson-server
Feel free to ask any further questions!
Best regards!
Hello hubert.K,
thanks for the quick reply, I tried 3 solutions online I still get the same error
""""RROR TypeError: Cannot read properties of undefined (reading '0')
at f (map.js:54:192)
at map.js:55:1
at Array.map (<anonymous>)
at f (map.js:54:376)
at d.getGeoMap (map.js:87:17)
at map.js:83:100
at Array.map (<anonymous>)
at new d (map.js:83:81)
at m.<anonymous> (map.js:104:1)
at highcharts.js:18:179
defaultErrorLogger @ core.mjs:6485"""", I think the exported format of these solutions is not what you expect in Highmaps
This error is meaning that your file has an undefined value in some variables in JSON. It's hard to say what could be done without your GeoJSON and parsed TopoJSON files. I can suggest you see our official TopoJSON files here: https://code.highcharts.com/mapdata and maybe somehow compare them with your parsed file.
If it's helpful for others, I believe the issue here is that these conversion tools can give you geometry objects that do not have an arcs property. Like this:
{
"type": null,
"id": 51685
},
I'm not sure why. Highcharts expects there to be arcs though, if you filter out the objects with "type: null" it should work