'How to disable the device rotation animation in SwiftUI?

For UIKit to disable the device rotation animation you could override the viewWillTransitionToSize method. Disable orientation change rotation animation But what would be the best way to achieve this in SwiftUI?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source