Use Location Services
4 fill-in slots · from The AI Prompt Handbook for Mobile App Development
Your details
0/4 filledUse Location Services
Background: Native [platform] app, [SwiftUI / Compose]. Location need: [one-time fix / continuous foreground / background updates / geofencing]. Accuracy required: [precise / approximate / coarse]. Feature: [what it's for]. Use case: Implement location access for exactly the level I need—no more, because over-asking gets rejected and drains battery. Implementation details: - Request the minimum: when-in-use before always; precise vs approximate (iOS reduced accuracy / Android coarse location) - iOS: CLLocationManager authorization flow, the "Always" upgrade prompt timing, and background location modes if truly needed. Android: foreground vs background location permission (separate request on modern Android), and a foreground service for ongoing tracking. - Battery-conscious settings: desired accuracy, distance filter, stopping updates when not needed - Handling denied/reduced accuracy gracefully - Privacy declarations the store will check Layer & dependencies: Location updates exposed as an observable stream the feature consumes; manager lifecycle tied to need, not app lifetime. Deliverable: The location implementation for my exact need, the authorization flow (including any upgrade prompt), the battery-saving configuration, the reduced/denied handling, and the privacy-declaration notes.
Highlighted [slots] are still empty. Downloads are plain .txt — paste into any AI assistant.