tableView(_:trailingSwipeActionsConfigurationForRowAt:)
Returns the swipe actions to display on the trailing edge of the row.
Declaration
optional func tableView(_ tableView: UITableView, trailingSwipeActionsConfigurationForRowAt indexPath: IndexPath) -> UISwipeActionsConfiguration?Parameters
- tableView:
The table view containing the row.
- indexPath:
The index path of the row.
Return Value
The swipe actions to display next to the trailing edge of the row. Return nil if you want the table to display the default set of actions.
Discussion
Use this method to return a set of actions to display when the user swipes the row. The actions you return are displayed on the trailing edge of the row. For example, in a left-to-right language environment, they are displayed on the right side of the row when the user swipes from right to left.