SwiftUI 有哪些新特性
Asked on 06/12/2025
1 search
在 WWDC 上,SwiftUI 引入了许多新特性和改进。以下是一些主要的更新:
-
图形能力:SwiftUI 现在支持新的图形功能,包括颜色混合和自定义着色器的预编译,以避免因懒惰的着色器编译导致的帧丢失。What’s new in SwiftUI
-
滚动视图控制:提供了更细粒度的滚动视图控制,允许对内容偏移、内容大小等变化进行高效反应。What’s new in SwiftUI
-
SF Symbols 6:引入了新的动画效果,如摇摆、呼吸和旋转效果,增强了现有的动画预设。What’s new in SwiftUI
-
性能改进:在 macOS 上,列表加载速度提高了 6 倍,更新速度提高了 16 倍,滚动性能也有显著提升。What’s new in SwiftUI
-
文本编辑和选择:SwiftUI 现在提供了对文本选择的编程访问和控制,支持富文本编辑。Platforms State of the Union
-
3D 图表和布局:支持 3D 图表和布局,增强了与 RealityKit 的集成。Platforms State of the Union
-
窗口和输入方法:在 macOS 上,提供了更多的窗口样式和行为定制选项。What’s new in SwiftUI
这些更新使得 SwiftUI 更加强大和灵活,适用于构建跨 Apple 平台的现代应用程序。

What’s new in SwiftUI
Learn how you can use SwiftUI to build great apps for any Apple platform. Explore a fresh new look and feel for tabs and documents on iPadOS. Improve your window management with new windowing APIs, and gain more control over immersive spaces and volumes in your visionOS apps. We’ll also take you through other exciting refinements that help you make expressive charts, customize and layout text, and so much more.

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.

Platforms State of the Union
Discover the newest advancements on Apple platforms.