---
title: "behavior(_:)"
framework: swiftui
role: symbol
role_heading: Instance Method
path: "swiftui/hovereffectgroup/behavior(_:)"
---

# behavior(_:)

Returns a new version of self with the given behavior.

## Declaration

```swift
func behavior(_ behavior: HoverEffectGroup.Behavior) -> HoverEffectGroup
```

## Parameters

- `behavior`: How the effect will behave relative to other effects in the group.

## Return Value

Return Value A new HoverEffectGroup with the given behavior.
