SwiftUI 在 iOS 26 和 macOS 26 上的新特性
Asked on 2025-08-01
1 search
在 WWDC 2025 上,SwiftUI 在 iOS 26 和 macOS 26 上引入了一些令人兴奋的新特性和改进。以下是一些主要更新:
-
新设计系统:SwiftUI 引入了一个新的设计系统,使得应用程序在所有 Apple 平台上都能提供明亮且流畅的体验。导航容器和工具栏在 iPad 和 macOS 上获得了更新,具有玻璃外观,反映周围的内容。了解更多关于新设计的内容(01:22)。
-
性能改进:SwiftUI 在性能方面有显著提升,特别是在列表、滚动和分析方面。macOS 上的列表加载速度提高了 6 倍,更新速度提高了 16 倍。查看性能改进的详细信息(06:59)。
-
3D 布局和空间体验:SwiftUI 现在支持在 Vision OS 上进行 3D 布局,允许在同一 3D 空间中对齐重叠内容,并使用 3D 锚点偏好设置将内容锚定到特定位置。了解更多关于空间布局的内容(14:33)。
-
与 RealityKit 的集成:SwiftUI 和 RealityKit 的集成得到了增强,包括附加组件、动画同步、组件绑定和 RealityView 的新尺寸行为。了解更多关于 SwiftUI 和 RealityKit 的集成(20:04)。
这些更新使得 SwiftUI 在 iOS 26 和 macOS 26 上更加强大和灵活,为开发者提供了更多工具来创建引人入胜的应用体验。

Build a SwiftUI app with the new design
Explore the ways Liquid Glass transforms the look and feel of your app. Discover how this stunning new material enhances toolbars, controls, and app structures across platforms, providing delightful interactions and seamlessly integrating your app with the system. Learn how to adopt new APIs that can help you make the most of Liquid Glass.

What’s new in SwiftUI
Learn what’s new in SwiftUI to build great apps for any Apple platform. We’ll explore how to give your app a brand new look and feel with Liquid Glass. Discover how to boost performance with framework enhancements and new instruments, and integrate advanced capabilities like web content and rich text editing. We’ll also show you how SwiftUI is expanding to more places, including laying out views in three dimensions.

What’s new in UIKit
Modernize your app with the latest APIs in UIKit, including enhanced menu bar support, automatic observation tracking, a new UI update method, and improvements to animations. We’ll also cover how you can include SwiftUI scenes in your UIKit app and explore SF Symbols, HDR color pickers, and more.