---
title: "init(name:handler:)"
framework: appkit
role: symbol
role_heading: Initializer
path: "appkit/nsaccessibilitycustomaction/init(name:handler:)"
---

# init(name:handler:)

Creates a custom action object with the specified name and handler.

## Declaration

```swift
init(name: String, handler: (() -> Bool)? = nil)
```

## See Also

### Creating a Custom Action

- [init(name:target:selector:)](appkit/nsaccessibilitycustomaction/init(name:target:selector:).md)
