swift-patterns
Expert SwiftUI assistant for reviewing, refactoring, and building high-performance, testable, and modern iOS applications using Apple's best practices.
Introduction
The swift-patterns skill acts as a comprehensive knowledge base and assistant for developers working with SwiftUI and the modern Swift ecosystem. It provides actionable guidance for managing view state, architecting navigation flows, implementing complex view composition, and optimizing rendering performance. Whether you are modernizing a legacy codebase, resolving complex re-rendering issues, or starting a new feature, this skill helps ensure your code aligns with Appleās latest architectural guidance, such as leveraging the @Observable macro, NavigationStack, and efficient async patterns with .task.
-
Expert analysis of SwiftUI property wrapper selection including @State, @Binding, @Bindable, and @Environment.
-
Automated review and refactoring checklists covering memory management, view identity stability, and anti-pattern identification.
-
In-depth migration guides for updating deprecated APIs like NavigationView, foregroundColor, and manual state synchronization to modern iOS standards.
-
Advanced performance strategies for large lists, lazy container utilization, and minimizing view body recomputation.
-
Standardized workflows for code reviews and feature implementation, focused on testability and modular, decoupled code structures.
-
Fact-based, neutral guidance that does not impose specific high-level architectures but focuses on technical correctness and clean code principles.
-
Usage: Provide the assistant with file paths or code snippets for review, or ask specific questions about SwiftUI API behavior and pattern implementation.
-
Input: SwiftUI view code, state management models, navigation logic, and performance concerns.
-
Output: Actionable code improvements, refactoring steps, identification of common smells like duplicate sources of truth, and clear evidence-based explanations.
-
Constraints: Focuses primarily on SwiftUI and modern Swift; avoids enforcing heavy architectural frameworks like TCA or MVVM to keep usage lightweight and context-agnostic.
Repository Stats
- Stars
- 7
- Forks
- 1
- Open Issues
- 1
- Language
- Not provided
- Default Branch
- main
- Sync Status
- Idle
- Last Synced
- May 3, 2026, 10:02 PM