---
title: "init(id:title:perform:)"
framework: tipkit
role: symbol
role_heading: Initializer
path: "tipkit/tips/action/init(id:title:perform:)"
---

# init(id:title:perform:)

Creates a tip action that generates its label from a string.

## Declaration

```swift
@preconcurrency nonisolated init(id: String? = nil, title: some StringProtocol, perform handler: @escaping @MainActor @Sendable () -> Void = {})
```

## Parameters

- `id`: An optional identifier associated with the action. If you don’t specify a value, the system assigns the action’s index to this value.
- `title`: A string that describes the purpose of the tip action.
- `handler`: The function the system calls when the action triggers.

## See Also

### Initializers

- [init(id:perform:_:)](tipkit/tips/action/init(id:perform:_:).md)
