---
title: "sectionActions(content:)"
framework: swiftui
role: symbol
role_heading: Instance Method
path: "swiftui/view/sectionactions(content:)"
---

# sectionActions(content:)

Adds custom actions to a section.

## Declaration

```swift
nonisolated func sectionActions<Content>(@ContentBuilder content: () -> Content) -> some View where Content : View

```

## Discussion

Discussion On iOS, the actions are displayed as items after the content of the section. On macOS, the actions are displayed when a user hovers over the section. The following example adds an ‘Add’ button to the ‘Categories’ section. List {     Label("Home", systemImage: "house")     Label("Alerts", systemImage: "bell")

Section("Categories") {         Label("Climate", systemImage: "fan")         Label("Lights", systemImage: "lightbulb")     }     .sectionActions {         Button("Add Category", systemImage: "plus") { }     } }

## See Also

### Configuring a tab

- [TabPlacement](swiftui/tabplacement.md)
- [TabContentBuilder](swiftui/tabcontentbuilder.md)
- [TabContent](swiftui/tabcontent.md)
- [AnyTabContent](swiftui/anytabcontent.md)
