topojson 0.1.0 copy "topojson: ^0.1.0" to clipboard
topojson: ^0.1.0 copied to clipboard

outdated

A Dart port of topojson.

topojson #

A Dart port of topojson/topojson-client.

It only implements feature function that can be used to convert TopoJSON to GeoJSON.

/// topojson to geojson conversion
final resp = await http.get(
    Uri.parse('https://geoshape.ex.nii.ac.jp/jma/resource/AreaInformationCity_landslide/20210518/4220201.topojson'));
final topoJson = jsonDecode(utf8.decode(resp.bodyBytes));

final f = feature(topoJson, topoJson['objects']['area']);
final geoJson = jsonEncode(f);

await io.File('4220201.geojson').writeAsString(geoJson);
1
likes
0
points
31
downloads

Publisher

verified publisherespresso3389.jp

Weekly Downloads

A Dart port of topojson.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

collection, http

More

Packages that depend on topojson