---
title: "selection(_:)"
framework: swiftui
role: symbol
role_heading: Type Method
path: "swiftui/sensoryfeedback/selection(_:)"
---

# selection(_:)

Plays feedback in response to a specific UI element’s values changing.

## Declaration

```swift
static func selection(_ feedback: SensoryFeedback.SelectionFeedback) -> SensoryFeedback
```
