A control that performs an action when triggered.
SDKs
- iOS 13.0+
- macOS 10.15+
- Mac Catalyst 13.0+
- tvOS 13.0+
- watchOS 6.0+
- Xcode 11.0+
Framework
- Swift
UI
Declaration
struct Button<Label> where Label : View
Overview
The method of “triggering” the button may vary. For example, on iOS a button is triggered by tapping it onscreen, whereas on tvOS it’s triggered by pressing “select” on an external remote while the button is focused.