Swift version: 5.1
There’s a lot of animation in UIKit, and many users find it either distracting or hard to follow. As a result, iOS has a Reduce Motion accessibility setting that disables many animation and parallax effects, and simplifies most others – at least in their own apps.
If you want to follow suit – and you should – all you need to do is call
UIAccessibilityIsReduceMotionEnabled(). This returns a boolean telling you whether the setting is active or not, so if it’s true you should take steps to animate differently or perhaps not at all.
LEARN SWIFTUI FOR FREE I have a massive, free SwiftUI video collection on YouTube teaching you how to build complete apps with SwiftUI – check it out!
Available from iOS 8.0
This is part of the Swift Knowledge Base, a free, searchable collection of solutions for common iOS questions.