FunctioniOS 13.0+
Overloads
2 ways to call withAnimation(). Each is one SwiftUI overload, picked by the arguments you pass.
function withAnimation<Result>(body: () => Result): Result
function withAnimation<Result>(
animation: SwiftUI.Animation | null,
body: () => Result
): Resultfunc withAnimation<Result>(
_ animation: Animation? = .default,
_ body: () throws -> Result
) rethrows -> ResultParameters
body*() => Resultanimation*SwiftUI.Animation | null
See also
More in SwiftUI functions.
- createNavigationPathStarts a SwiftUI NavigationPath. Each call returns a new value, as compose() does.
- createPathStarts a SwiftUI Path. Each call returns a new value, as compose() does.
- createScrollPositionStarts a SwiftUI ScrollPosition. Each call returns a new value, as compose() does.
- createTabViewCustomizationStarts a SwiftUI TabViewCustomization. Each call returns a new value, as compose() does.
- createTransactionStarts a SwiftUI Transaction. Each call returns a new value, as compose() does.
- withTransactionExecutes a closure with the specified transaction key path and value and returns the result.