{ "$schema": "https://raw.githubusercontent.com/guitaripod/wwdc-sessions/master/schema/session.schema.json", "schemaVersion": 1, "id": "wwdc2026-278", "event": "wwdc2026", "eventName": "WWDC26", "year": 2026, "eventContentId": 278, "title": "Modernize your UIKit app", "description": "Discover the latest updates to UIKit. Learn how to update your iPhone app layouts to work great when resized with iPhone Mirroring and on iPad. Explore new APIs for tab and navigation bars, find out how to prepare your app for new Apple Intelligence capabilities, and get introduced to a skill for your coding agent of choice that helps modernize your codebase.", "url": "https://developer.apple.com/videos/play/wwdc2026/278", "sosumiURL": "https://sosumi.ai/videos/play/wwdc2026/278", "type": "Video", "publishedAt": "2026-06-08T14:00:00-07:00", "platforms": [ "iOS", "iPadOS", "macOS", "tvOS", "visionOS" ], "keywords": [ "⚡️" ], "topics": [ "SwiftUI & UI Frameworks" ], "primaryTopic": "SwiftUI & UI Frameworks", "duration": 963, "hasTranscript": true, "transcriptWordCount": 2429, "availableLanguages": [ "eng", "fra", "jpn", "kor", "por", "spa", "zho" ], "media": { "hls": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/278/4/8c3f2e61-52d3-4915-9543-96e2f13adc8b/cmaf.m3u8", "downloadHLS": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/278/4/8c3f2e61-52d3-4915-9543-96e2f13adc8b/cmaf-download.m3u8", "downloadSD": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/278/4/8c3f2e61-52d3-4915-9543-96e2f13adc8b/downloads/wwdc2026-278_sd.mp4", "downloadHD": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/278/4/8c3f2e61-52d3-4915-9543-96e2f13adc8b/downloads/wwdc2026-278_hd.mp4", "duration": 963 }, "codeSnippets": [ { "title": "Use local screen references", "language": "swift", "startTimeSeconds": 204, "code": "// Use local screen references\n// Access the correct screen through a windowScene\nlet screen = window?.windowScene?.screen\n\n// Pass in local screen references\nfunc generateThumbnail(_ image: UIImage, screen: UIScreen) -> UIImage {\n // existing code, replacing main screen with local screen reference\n // ...\n}" }, { "title": "Replace screen scale with displayScale", "language": "swift", "startTimeSeconds": 229, "code": "// Replace the screen's scale with trait collection's displayScale\noverride func layoutSubviews() {\n super.layoutSubviews()\n\n // layoutSubviews will be called again automatically when displayScale changes\n let displayScale = traitCollection.displayScale\n // ...\n}" }, { "title": "Register for trait changes", "language": "swift", "startTimeSeconds": 276, "code": "// Manually register for trait changes\nlet displayScaleTrait: [UITrait] = [UITraitDisplayScale.self]\nregisterForTraitChanges(displayScaleTrait) {\n (view: GalleryView, previousTraitCollection: UITraitCollection) in\n view.cache.invalidate()\n}" }, { "title": "Monitor effective geometry changes", "language": "swift", "startTimeSeconds": 319, "code": "// UIWindowSceneDelegate\nfunc windowScene(\n _ windowScene: UIWindowScene,\n didUpdateEffectiveGeometry previousEffectiveGeometry: UIWindowScene.Geometry\n) {\n let geometry = windowScene.effectiveGeometry\n let availableSpace = geometry.coordinateSpace.bounds\n // ...\n}" }, { "title": "Check available space using view bounds", "language": "swift", "startTimeSeconds": 335, "code": "// Checking available space\noverride func viewDidLayoutSubviews() {\n super.viewDidLayoutSubviews()\n\n let availableSpace = view.bounds.size\n // ...\n}" }, { "title": "Configure motion and location body", "language": "swift", "startTimeSeconds": 492, "code": "// Configure motion and heading bodies\noverride func viewDidLoad() {\n super.viewDidLoad()\n\n motionManager.deviceMotionBody = view\n locationManager.headingBody = view\n}" }, { "title": "Opt into sidebar layout", "language": "swift", "startTimeSeconds": 591, "code": "tabBarController.sidebar.preferredPlacement = .sidebar" }, { "title": "Check sidebar availability", "language": "swift", "startTimeSeconds": 622, "code": "tabBarController.sidebar.isAvailable" }, { "title": "Set prominent tab identifier", "language": "swift", "startTimeSeconds": 653, "code": "// Set the prominent tab\nlet tabs = [\n // ...\n]\nlet tabBarController = UITabBarController(tabs: tabs)\ntabBarController.prominentTabIdentifier = \"cart\"" }, { "title": "Customize bar minimization behavior", "language": "swift", "startTimeSeconds": 690, "code": "// Customize bar minimization behavior\noverride init(\n nibName nibNameOrNil: String?,\n bundle nibBundleOrNil: Bundle?\n) {\n super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil)\n\n navigationItem.navigationBarMinimization.minimizationBehavior = .onScrollDown\n navigationItem.navigationBarMinimization.safeAreaAdjustment = .disabled\n}" }, { "title": "Export Xcode skills for use in other tools", "language": "bash", "startTimeSeconds": 905, "code": "xcrun agent skills export" } ], "resources": [ { "title": "TN3208: Preparing your app’s launch screen to meet App Store requirements", "url": "https://developer.apple.com/documentation/Technotes/tn3208-preparing-your-apps-launch-screen-to-meet-app-store-requirements", "type": "documentation", "description": "Understand the launch screen requirement for App Store submission starting in iOS 27 and iPadOS 27.", "sosumiURL": "https://sosumi.ai/documentation/Technotes/tn3208-preparing-your-apps-launch-screen-to-meet-app-store-requirements", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/Technotes/tn3208-preparing-your-apps-launch-screen-to-meet-app-store-requirements.json" }, { "title": "TN3210: Optimizing your app for iPhone Mirroring", "url": "https://developer.apple.com/documentation/Technotes/tn3210-optimizing-your-app-for-iphone-mirroring", "type": "documentation", "description": "Test your app and improve compatibility with iPhone Mirroring.", "sosumiURL": "https://sosumi.ai/documentation/Technotes/tn3210-optimizing-your-app-for-iphone-mirroring", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/Technotes/tn3210-optimizing-your-app-for-iphone-mirroring.json" }, { "title": "Make your UIKit app more flexible", "url": "https://developer.apple.com/videos/play/wwdc2025/282/", "type": "guide", "description": "Find out how your UIKit app can become more flexible on iPhone, iPad, Mac, and Apple Vision Pro by using scenes and container view controllers. Learn to unlock your app's full potential by transitioning from an app-centric to a scene-based lifecycle, including enhanced window resizing and improved multitasking. Explore enhancements to UISplitViewController, such as interactive column resizing and first-class support for inspector columns. And make your views and controls more adaptive by adopting new layout APIs.", "sosumiURL": "https://sosumi.ai/videos/play/wwdc2025/282/" }, { "title": "Adapting your app when traits change", "url": "https://developer.apple.com/documentation/UIKit/adapting-your-app-when-traits-change", "type": "documentation", "description": "Find out when system changes happen that affect your app, then update your app efficiently.", "sosumiURL": "https://sosumi.ai/documentation/UIKit/adapting-your-app-when-traits-change", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/UIKit/adapting-your-app-when-traits-change.json" }, { "title": "Transitioning to the UIKit scene-based life cycle", "url": "https://developer.apple.com/documentation/UIKit/transitioning-to-the-uikit-scene-based-life-cycle", "type": "documentation", "description": "Adopt the scene-based life cycle to replace the app delegate life cycle in UIKit.", "sosumiURL": "https://sosumi.ai/documentation/UIKit/transitioning-to-the-uikit-scene-based-life-cycle", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/UIKit/transitioning-to-the-uikit-scene-based-life-cycle.json" }, { "title": "Automatic trait tracking", "url": "https://developer.apple.com/documentation/UIKit/automatic-trait-tracking", "type": "documentation", "description": "Reduce the need to manually register for trait changes when you use traits within a method or closure that supports automatic trait tracking.", "sosumiURL": "https://sosumi.ai/documentation/UIKit/automatic-trait-tracking", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/UIKit/automatic-trait-tracking.json" }, { "title": "Human Interface Guidelines: Menus", "url": "https://developer.apple.com/design/human-interface-guidelines/menus", "type": "documentation", "description": "HIG", "sosumiURL": "https://sosumi.ai/design/human-interface-guidelines/menus" } ], "path": "sessions/wwdc2026/278-modernize-your-uikit-app/", "files": { "metadata": "sessions/wwdc2026/278-modernize-your-uikit-app/metadata.json", "readme": "sessions/wwdc2026/278-modernize-your-uikit-app/README.md", "transcript": "sessions/wwdc2026/278-modernize-your-uikit-app/transcript.md", "transcriptJSON": "sessions/wwdc2026/278-modernize-your-uikit-app/transcript.json" } }