Documentation

SwiftUI Location Permissions View

A SwiftUI View for introducing and initiating a system request for location access from the user.

LocationPermissionsView with a light color scheme. A SwiftUI Starter Kit Component.
LocationPermissionsView with a light color scheme.
LocationPermissionsView with a dark color scheme. A SwiftUI Starter Kit Component.
LocationPermissionsView with a dark color scheme.

Usage

LocationPermissionsView(
    interactor: .init(
        didSelectEnable: {},
        didSelectSkip: {}
    )
)

Features

  • Supports light and dark device color schemes by default.
  • Supports font scaling via Dynamic Type.
  • Supports offline usage in SwiftUI Previews for easy debugging and testing.

Notes

  • Use LocationController to request system location access authorization, or respond to gps location updates via CLLocationManagerDelegate.