Scene phase
Also called: App state, ScenePhase
Whether an iOS app's scene is active, inactive or in the background, which decides what it may do and when it should save.
Definition
Active means in front and receiving touches; inactive means visible but briefly interrupted (Control Center, the app switcher, a call); background means not visible, with a few seconds before the app is suspended. Suspended apps can be terminated without any callback, so user data is saved when the scene enters the background.
In practice
.onChange(of: scenePhase) saves the draft when the phase becomes .background.