application(_:configurationForConnecting:options:)
Retrieves the configuration data for UIKit to use when creating a new scene.
Declaration
optional func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfigurationParameters
- application:
The singleton app object.
- connectingSceneSession:
The session object associated with the scene. This object contains the initial configuration data loaded from the app’s
Info.plistfile, if any. - options:
System-specific options for configuring the scene.
Mentioned in
Return Value
The configuration object containing the information needed to create the scene.
Discussion
Implement this method if you don’t include scene-configuration data in your app’s Info.plist file, or if you want to alter the scene configuration data dynamically. UIKit calls this method shortly before creating a new scene. In your implementation, return a UISceneConfiguration object with the scene details, including the type of scene to create, the delegate object you use to manage the scene, and the storyboard containing the initial view controller to display.
If you don’t implement this method, you must provide scene-configuration data in your app’s Info.plist file.