mapbox / mapbox/mapbox-maps-flutter

Leverage Turf for Geometry in TileRegionLoadOptions

Open
#607 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Dart
Stars
380
Forks
204
PR merge metrics
No merged PRs in 30d

Description

Most API use the Turf classes, however `TileRegionLoadOptions` has a field `geometry` which is of type `Map?` instead of `turf.GeometryType?`. Since this is defined in a pigeon generated file and the sources from which those files are generated are not public I'm unfortunately not able to submit a PR. @maios Is there any reason why the field does not use `turf.GeometryType` or was this just forgotten?
https://github.com/mapbox/mapbox-maps-flutter/blob/e688ca96c76c0c58d4dcb7c723bdaf625e41f6b8/lib/src/offline/offline_messenger.dart#L348

Also why is `descriptorOptions` of type `List?` and not `List?` ?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in lib/src/offline/offline_messenger.dart around line 348 and inspect the generated TileRegionLoadOptions API. Compare the geometry and descriptorOptions types with the corresponding Turf-based API usage. Done means the intended types and nullability are consistent in the generated interface, though the issue notes that the source definitions are not public.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart, flutter
Domain
api, mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.