mapbox_search
4.4.0, released 11 months ago by ketanchoyal.dev
Flutter package for place search using MapBox API and static map image generation.
WASM-ready
What it does
Provides easy API calls to MapBox Search API for forward geocoding, reverse geocoding, search box suggestions, batch geocoding, and static map image generation with markers and polylines.
AI-written summary of version 4.4.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need Mapbox geocoding or search functionality in your app
- You want to generate static map images with polylines and markers
Skip it when
- You require a fully interactive embedded map widget (use a map rendering package instead)
- You are using Google Maps services instead of Mapbox
Strengths
- Supports modern Mapbox APIs including SearchBox and Batch Geocoding
- Includes static map image generation with custom markers and paths
- Uses safe ApiResponse records to handle success and failure flows
Weaknesses
- Does not render interactive map views, only handles API calls and static images
- Requires Dart 3.0 or higher
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- Yes (build_runner)
- Direct dependencies
- 5
Acquire an API key on the Mapbox website and initialize it globally by calling MapBoxSearch.init('API KEY') in your main function.
var geocoding = GeoCoding(apiKey: 'API Key', limit: 5);
Future<ApiResponse<List<MapBoxPlace>>> getPlaces() => geocoding.getPlaces('central park');Alternatives
Packages that do the same job and could replace mapbox_search.
Works with
Packages commonly used together with mapbox_search: ones it builds on, ones built on it, and its own family.
- uuidmapbox_search depends on itGenerates and parses RFC‑4122/9562 UUIDs (v1‑v8) for Dart.
- json_annotationmapbox_search depends on itProvides annotations for json_serializable to generate JSON (de)serialization code.
- diomapbox_search depends on itA powerful HTTP networking package for Dart and Flutter with interceptors and request cancellation.
- colormapbox_search depends on itCreate, convert, alter, and compare colors in various colorspaces.