发现和使用优秀的技能扩展
重构和审查SwiftUI视图文件,以确保结构一致、依赖注入合理以及观察机制(Observation)的正确使用。当需要清理SwiftUI视图的布局/排序、安全地处理视图模型(尽可能使用非可选类型),或者标准化依赖项和@Observable状态的初始化与传递方式时,可采用此方法。
Refactor and review SwiftUI view files for consistent structure, dependency injection, and Observation usage. Use when asked to clean up a SwiftUI view’s layout/ordering, handle view models safely (non-optional when possible), or standardize how dependencies and @Observable state are initialized and passed.