Preparing React Native apps for iOS 15 and Android 12
The React Native blog has published guidance on getting apps ready for the new mobile OS versions arriving later this year, with the aim of avoiding regressions once iOS 15 and Android 12 become generally available.
iOS 15
The release date of iOS 15 had not been announced, but based on past releases the post expects it around September 16th. Developers are advised to factor in App Store review time if changes are needed.
QuickType bar. The method for hiding the QuickType bar (the bar above the keyboard showing three suggested words) in TextInput has changed. On iOS 15, setting autoCorrect to false alone no longer hides it; spellCheck must also be set to false. This also turns off spell check and its red underlines, and hiding the QuickType bar while keeping spell check enabled is no longer possible.
<TextInput
placeholder="something"
autoCorrect={false}
spellCheck={false}
/>
Transparent navigation bar. iOS 15 changes the navigation bar's default behaviour: unlike iOS 14, it becomes transparent when content is scrolled all the way up, which can make content harder to read. The post links to a thread with workaround tips.
Testing. iOS 15 can be installed on a spare device through the beta program; the post notes beta releases are generally stable at this point, but the upgrade cannot be reversed. Testing on a simulator requires Xcode 13.
Android 12
Android 12 will be released this autumn. The post notes that Google Play has traditionally required apps to upgrade their target SDK before November of the following year.
Overscroll effect. Android 12 adds a new overscroll effect to all scroll containers. Because React Native scroll views are based on native views, the team recommends checking scrollable containers to confirm the effect is applied correctly. It can be disabled by setting the overScrollMode prop to never.
Permission updates. When an app requests the ACCESS_FINE_LOCATION permission, Android 12 lets users grant access to only their approximate location.
The post also points to Google's detailed list of behavior changes affecting all apps running on Android 12.
Testing. Developers with a spare Android device can check whether it can install the Android 12 Beta; otherwise, an emulator can be set up instead.
Links
Source: reactnative.dev