Documentation

SwiftUI Notification Permissions View

A SwiftUI View for introducing and initiating a push notification system permissions request to the user.

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

Usage

NotificationPermissionsView(
    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 this view in tandem with NotificationController to request permission authorization from the operating system.