Post

Replies

Boosts

Views

Activity

Opting into dark mode does not get picked up by app update
Our app has previously not supported dark mode and we had the "Appearance" entry in our Info.plist set to "Light". We are now about to release an update that enables dark mode support. To enable this we have: Added a preference to our app's settings screen that lets users choose between System, Light and Dark options. Based on the user's preference, we set the entire app's preferred color scheme using the SwiftUI .preferedColorScheme modifier on our root view. Removed the "Appearance" entry from our Info.plist This is all tested and working in our local development builds. We are now testing out the app for release using an internal TestFlight build and we've run into a problem - after initially updating the app, it does not seem to detect the change to the Info.plist and the app remains in light mode even if you change the preferred colour scheme. If you force quite the app from the app switched and re-launch it, the colour scheme preference starts working as expected. This is going to be an issue for our users because when they update the app it is going to look like the new color scheme setting does not work. Having to ask customers to force quit the app from the app switcher is not really an acceptable workaround. I'm not sure this is specifically tied to the app process being killed because I would expect that to happen anyway when the app is updated. I'm wondering if this is related to the system caching the UISceneSession for the app and the act of force killing it from the app switcher is what causes the cached session to be created. Is this a known issue and is there any way to solve this?
2
0
457
Jul ’24