---
title: "init(context:label:)"
framework: localauthentication
role: symbol
role_heading: Initializer
path: "localauthentication/localauthenticationview/init(context:label:)"
---

# init(context:label:)

Creates a local authentication view with a label and required context.

## Declaration

```swift
@MainActor @preconcurrency init(context: LAContext, @ViewBuilder label: () -> Label)
```

## Parameters

- `context`: A context used to evaluate authentication policies.
- `label`: A label that displays below the authentication view.

## See Also

### Authenticating with a context you supply

- [init(_:context:)](localauthentication/localauthenticationview/init(_:context:)-9xeoo.md)
- [init(_:context:)](localauthentication/localauthenticationview/init(_:context:)-676qx.md)
