Contents

init(_:context:)

Creates a new view and pairs it with the specified authentication context.

Declaration

@MainActor @preconcurrency init(_ title: LocalizedStringResource, context: LAContext) where Label == Text

Parameters

  • title:

    Title shown below the authentication view.

  • context:

    LAContext instance to control the authentication.

Discussion

The authentication is controlled using the provided authentication context. When evaluatePolicy or evaluateAccessControl is called on this context, the UI will be presented using this view rather than using the standard authentication alert.