One-click install
npx skills add https://github.com/xtone/ai_development_tools --skill swift-ios-migration
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: swift-ios-migration
Source: https://github.com/xtone/ai_development_tools/tree/main/ios_development/skills/swift-ios-migration
Command: npx skills add https://github.com/xtone/ai_development_tools --skill swift-ios-migration

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps Swift developers migrate from legacy ObservableObject patterns to modern concurrency-friendly approaches, including @Observable, @MainActor guidance, and iOS 17 feature adoption. It streamlines identifying breaking changes, updating patterns, and aligning project settings for a safer upgrade.

Core Features & Use Cases

  • Migration guidance: Step-by-step strategies to upgrade models, view models, and environment usage to Swift 6.2+ concurrency.
  • Pattern modernization: Replace ObservableObject/Published with @Observable and adopt @MainActor defaults where appropriate.
  • Platform updates: Guidance for iOS 17+ Observable macro, iPadOS 26 windowing changes, and Swift 6.2 concurrency improvements.

Quick Start

Begin by reviewing references/ios17-observable.md to plan the first wave of changes, then migrate small ViewModels to @Observable, and iterate across the codebase. Use the references/ipados26-windowing.md to adjust layout and window management, and consult references/swift62-changes.md (and swift6-concurrency.md) for concurrency adjustments.

Frequently Asked Questions about swift-ios-migration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate ObservableObject to the @Observable macro in Swift?

Migrating ObservableObject to @Observable involves replacing the ObservableObject protocol and @Published properties with the @Observable macro. Start with small ViewModels, update environment usage, and iterate across the codebase.

What are the breaking changes when upgrading to Swift 6.2 concurrency?

Swift 6.2 concurrency upgrades introduce breaking changes requiring @MainActor defaults and Sendable type conformance. Use a checklist-driven upgrade plan to identify breaking changes, update patterns, and align project settings for a safer upgrade.

How do I make my Swift classes Sendable for modern concurrency?

Making Swift classes Sendable for modern concurrency requires adopting Sendable types and applying @MainActor defaults where appropriate. Follow concurrency-checking practices to align your models and ViewModels with Swift 6.2 standards.

Does this migration guide cover iPadOS 26 windowing changes?

Yes, the migration guide covers iPadOS 26 windowing changes. It provides specific guidance to adjust your layout and window management code to accommodate the new windowing paradigms introduced in iPadOS 26.

What's the best way to plan an iOS 17 migration for SwiftUI apps?

The best way to plan an iOS 17 migration is to use a checklist-driven upgrade plan. Review the ios17-observable reference first to plan your initial changes, then migrate ViewModels to @Observable and iterate.

Why do I need @MainActor defaults when adopting Swift 6 concurrency?

You need @MainActor defaults when adopting Swift 6 concurrency to ensure safe UI updates and prevent data races. Adopting @MainActor guidance aligns your project settings with modern concurrency-checking practices for a safer upgrade.