---
title: "insert(displayed:options:actionHandler:)"
framework: uikit
role: symbol
role_heading: Type Method
path: "uikit/uicellaccessory-swift.struct/insert(displayed:options:actionhandler:)"
---

# insert(displayed:options:actionHandler:)

Creates an insert system accessory with the specified display state, configuration options, and optional action handler.

## Declaration

```swift
static func insert(displayed: UICellAccessory.DisplayedState = .whenEditing, options: UICellAccessory.InsertOptions = InsertOptions(), actionHandler: UICellAccessory.ActionHandler? = nil) -> UICellAccessory
```

## Parameters

- `displayed`: The cell-editing states that the insert accessory appears in. This parameter has a default value of doc://com.apple.uikit/documentation/UIKit/UICellAccessory-swift.struct/DisplayedState/whenEditing.
- `options`: Configuration options for the insert accessory. See doc://com.apple.uikit/documentation/UIKit/UICellAccessory-swift.struct/InsertOptions for possible configuration options.
- `actionHandler`: An optional closure that the system calls when a user interacts with the insert accessory.

## Return Value

Return Value A configured insert cell accessory. This accessory is a plus sign inside of a circle with the default system green color. This accessory appears on the leading edge of the cell.

## See Also

### Creating an insert accessory

- [UICellAccessory.InsertOptions](uikit/uicellaccessory-swift.struct/insertoptions.md)
