<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "macOS: 13.0.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 9.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/CustomizableToolbarContent/customizationBehavior(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI26CustomizableToolbarContentPAAE21customizationBehavioryQrAA0d13CustomizationG0VF"
  },
  "title" : "customizationBehavior(_:)"
}
-->

# customizationBehavior(_:)

Configures the customization behavior of customizable toolbar content.

```
nonisolated func customizationBehavior(_ behavior: ToolbarCustomizationBehavior) -> some CustomizableToolbarContent
```

## Parameters

`behavior`

The customization behavior of the customizable
toolbar content.

## Discussion

Customizable toolbar items support different kinds of customization:

- A user can add an item that is not in the toolbar.
- A user can remove an item that is in the toolbar.
- A user can move an item within the toolbar.

Based on the customization behavior of the toolbar items, different
edits will be supported.

Use this modifier to the customization behavior a user can
perform on your toolbar items. In the following example, the
customizable toolbar item supports all of the different kinds of
toolbar customizations and starts in the toolbar.

```
ContentView()
    .toolbar(id: "main") {
        ToolbarItem(id: "new") {
            // new button here
        }
    }
```

You can create an item that can not be removed from the toolbar
or moved within the toolbar  by passing a value of
[`disabled`](/documentation/SwiftUI/ToolbarCustomizationBehavior/disabled) to this modifier.

```
ContentView()
    .toolbar(id: "main") {
        ToolbarItem(id: "new") {
            // new button here
        }
        .customizationBehavior(.disabled)
    }
```

You can create an item that can not be removed from the toolbar, but
can be moved by passing a value of
[`reorderable`](/documentation/SwiftUI/ToolbarCustomizationBehavior/reorderable).

```
ContentView()
    .toolbar(id: "main") {
        ToolbarItem(id: "new") {
            // new button here
        }
        .customizationBehavior(.reorderable)
    }
```

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)