Fully updated for Xcode 11.3
SwiftUI lets us specify one transition when adding a view and another when removing it, all done using the
asymmetric() transition type.
For example, we can create a text view that uses asymmetric transitions so that it moves in from the leading edge when added and moves down to the bottom edge when being removed, like this:
Text("Details go here.") .transition(.asymmetric(insertion: .move(edge: .leading), removal: .move(edge: .bottom)))
SPONSORED Why the top iOS apps rely on Instabug for crash reporting. Crash reporting + Bug reporting + Customizable in-app surveys all in one SDK. Know which line of code caused the crash along with network logs, repro steps, and the session profiler to identify and resolve severe crashes quickly. See more detailed features comparison and try Instabug for free here.