mapbox / mapbox/mapbox-maps-ios

Runtime styling types with IDs should conform to Identifiable

Open
#739 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-triaged feature :green_apple: v11
Dominant language
Swift
Stars
601
Forks
196
PR merge metrics
No merged PRs in 30d

Description

The `Annotation`, `AnnotationManager`, `Layer`, and `SourceInfo` protocols have the property `id`, which would satisfy the requirements of the Swift standard library’s `Identifiable` protocol. These protocols might as well explicitly conform to `Identifiable` as a formality.

Note that this feature request applies only to protocols that already define an `id` property. The `Identifiable` protocol also provides a default implementation for `AnyObject` that most likely returns the object’s memory address, something that probably would not be expected.

/ref mapbox/turf-swift#165
/cc @mapbox/maps-ios

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

Search the Swift sources for the Annotation, AnnotationManager, Layer, and SourceInfo protocol declarations and inspect their existing id properties. Update only the protocols that already define id to conform to Identifiable, then verify the project’s existing Swift checks pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
mobile-dev
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.