Skip to content
pubscout

geojson_vi

2.2.5, released 2 years ago by humg.edu.vn

Library for parsing, creating, and manipulating GeoJSON data per RFC 7946

WASM-ready
$ flutter pub add geojson_vi
Source repository

What it does

geojson_vi provides classes for all GeoJSON geometry types, features, and collections, allowing developers to parse from maps or JSON, construct new objects, and perform operations like searching and bbox calculations. It fully supports null geometry values and offers utility methods for point containment and optimal point placement.

AI-written summary of version 2.2.5, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to read or write GeoJSON files in a Dart/Flutter app
  • You want to manipulate GeoJSON features programmatically (create, update, delete)
  • You need to handle null geometry values according to the spec
  • You require utility methods for geometry calculations such as bbox or point containment

Skip it when

  • You only need to display GeoJSON on a map widget (use a mapping package instead)
  • You need high-performance spatial queries on large datasets (consider a dedicated spatial database)

Strengths

  • Comprehensive support for all GeoJSON geometry types
  • Built-in handling of null geometry values per RFC 7946
  • Simple, declarative API for creating and manipulating features
  • Utility methods for bbox, nearest feature, and point containment

Weaknesses

  • No built-in map rendering or UI components
  • No performance benchmarks for large datasets
  • Limited to GeoJSON; does not integrate with other spatial formats

Setup

Kind
Pure Dart
Effort
Low
Code generation
No
Direct dependencies
0
final point = GeoJSONPoint([105.7743099, 21.0717561]);
final feature = GeoJSONFeature(point, properties: {'title': 'Hanoi University'});
final collection = GeoJSONFeatureCollection([feature]);
print(collection.toJSON());

Alternatives

Packages that do the same job and could replace geojson_vi.

  • maps_launcher

    Simple plugin to open the native maps application or browser with coordinates or queries.

  • osrm

    Open Source Routing Machine (OSRM) client for Dart and Flutter.

  • geojson

    Utilities to parse GeoJSON data with a reactive API, search, and geofencing.

Works with

Packages commonly used together with geojson_vi: ones it builds on, ones built on it, and its own family.