topojson cannot convert file containing non-ASCII characters

55 views Asked by At

I'm trying to convert a GeoJSON file containing some non-ASCII, say Chinese, characters to TopoJSON, but the command 'topojson -o output.json -p --somegeojsonfile.json' cried out:

undefined:20606
{ "type": "Feature", "properties": { "NAME": "鍐堟媺姊呮湺\", "LAYER": "Unknown
Point
                                                       ^
SyntaxError: Unexpected token L
    at Object.parse (native)
    at inputJson (C:\Users\Watermelon\AppData\Roaming\npm\node_modules\topojson\
bin\topojson:245:21)
    at pop (C:\Users\Watermelon\AppData\Roaming\npm\node_modules\topojson\node_m
odules\queue-async\queue.js:24:14)
    at Object.q.defer (C:\Users\Watermelon\AppData\Roaming\npm\node_modules\topo
json\node_modules\queue-async\queue.js:55:11)
    at C:\Users\Watermelon\AppData\Roaming\npm\node_modules\topojson\bin\topojso
n:196:5
    at Array.forEach (native)
    at Object.<anonymous> (C:\Users\Watermelon\AppData\Roaming\npm\node_modules\
topojson\bin\topojson:195:8)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32).

how come? Any help would be much appreciated.

0

There are 0 answers