---
title: "addShortcut(_:)"
framework: browserenginekit
role: symbol
role_heading: Instance Method
path: "browserenginekit/berespondereditactions/addshortcut(_:)"
---

# addShortcut(_:)

Adds a text-replacement shortcut to the edit dictionary.

## Declaration

```swift
optional func addShortcut(_ sender: Any?)
```

## Parameters

- `sender`: The object calling this method.

## Discussion

Discussion To present the standard system UI for adding text-replacement shortcuts, call addShortcut(forText:from:) in your implementation of this method.

## See Also

### Finding and replacing text

- [findSelected(_:)](browserenginekit/berespondereditactions/findselected(_:).md)
- [promptForReplace(_:)](browserenginekit/berespondereditactions/promptforreplace(_:).md)
- [replace(_:)](browserenginekit/berespondereditactions/replace(_:).md)
