The best way to disable it is to provide a custom primitive button style that does not include the default tap animation. Here is the code to accomplish this:
struct NoTapAnimationStyle: PrimitiveButtonStyle {
func makeBody(configuration: Configuration) -> some View {
configuration.label
// Make the whole button surface tappable. Without this only content in the label is tappable and not whitespace. Order is important so add it before the tap gesture
.contentShape(Rectangle())
.onTapGesture(perform: configuration.trigger)
}
}
Then apply it with this modifier on the button:
.buttonStyle(NoTapAnimationStyle())
Repost of answer here: Disable default button click animation in SwiftUi