Scene-based app lifecycle
In a scene-based iOS app, where would you put work like registering the push token, and where would you put work like saving screen state: AppDelegate or SceneDelegate?
In a scene-based iOS app, where would you put work like registering the push token, and where would you put work like saving screen state: AppDelegate or SceneDelegate?
Work that happens once per process, such as getting the push token, handling launch options, and initializing SDKs, goes in AppDelegate, and work that happens per window, such as saving and restoring the screen across active and inactive transitions and stopping timers, goes in SceneDelegate (or scenePhase in SwiftUI).
SwiftUIShort answerIntro
In a SwiftUI app, what does @main mean?
#scene #appdelegate
App lifecycle and systemShort answerIntro
What kind of object is AppDelegate, and which events does it handle?
#appdelegate
App lifecycle and systemMultiple choiceBasics
In an iOS 13+ scene-based UIKit app (one that uses SceneDelegate), which callback runs…
#appdelegate
App lifecycle and systemShort answerAdvanced
You support the same music playback screen on iPhone, iPad, and CarPlay. When the app has…
#scene