Use when writing, reviewing, or refactoring SwiftUI code for iOS or macOS, including state management and `@Observable` data flow, view composition and invalidation/performance, lists and `ForEach` identity, environment usage, localization, animations, Liquid Glass adoption, migrating soft-deprecated APIs, or Instruments `.trace` capture/analysis for hangs, hitches, CPU hotspots, or excessive view updates.
SkillScore95Maintained
Automatic
◆Frontend / UI pack
Last verified 9/2/2026
What it changes
Passed 21 of 22 test cases with the skill, and 20 of 22 without it.
Without skill91%
With skill95%
Checks it passed that the model alone missed
The view uses glassEffect or GlassEffectContainer for iOS 26 visual glass styling.
The view includes an availability check for iOS 26 with fallback styling for earlier releases.
1 fixed20 passed either way1 still failing0 broke
Pass-rate lift
+5 pp
Tokens
+142%
Agent turns
0%
Response time
-13%
Model gemini-3.6-flashMeasured 9/2/2026v221 of 22 cases passed with skill
Tokens, turns and time describe resource use, not a dollar price.
See it in action
A test case the skill fixed. Same model, same prompt, with and without the skill.
Prompt
I need a new interactive settings card component for my iOS app that includes toggle actions and quick buttons, built with the latest iOS 26 visual glass styling and appropriate fallbacks for earlier releases. Please produce the complete data model and SwiftUI view code.
What was checked, without and with the skill
Checked
Without skill
With skill
The view uses glassEffect or GlassEffectContainer for iOS 26 visual glass styling.
Missed
Passed
The view includes an availability check for iOS 26 with fallback styling for earlier releases.
Missed
Passed
case-02 · gemini-3.6-flash · 9/2/2026 · answers are capped and redacted
What's inside
The instructions your model reads when the skill loads.
SKILL.md268 lines10 files
SwiftUI Expert Skill
Overview
Use this skill to build, review, or improve SwiftUI features with correct state management, modern API usage, Swift concurrency best practices, optimal view composition, and iOS 26+ Liquid Glass styling. Prioritize native APIs, Apple design guidance, and performance-conscious patterns. This skill focuses on facts and best practices without enforcing specific architectural patterns.
When to Use This Skill
Use this skill when:
Building new SwiftUI features
Refactoring existing SwiftUI views
Reviewing SwiftUI code quality
Adopting modern SwiftUI patterns
Working with SwiftUI state management
Implementing iOS 26+ Liquid Glass styling
Workflow Decision Tree
1) Review existing SwiftUI code
Check property wrapper usage against the selection guide (see references/state-management.md)
Verify modern API usage (see references/modern-apis.md)
Verify view composition follows extraction rules (see references/view-structure.md)
Check performance patterns are applied (see references/performance-patterns.md)
Verify list patterns use stable identity (see references/list-patterns.md)
Inspect Liquid Glass usage for correctness and consistency (see references/liquid-glass.md)
Validate iOS 26+ availability handling with sensible fallbacks
2) Improve existing SwiftUI code
Audit state management for correct wrapper selection (prefer @Observable over ObservableObject)
Replace deprecated APIs with modern equivalents (see references/modern-apis.md)
Extract complex views into separate subviews (see references/view-structure.md)
Refactor hot paths to minimize redundant state updates (see references/performance-patterns.md)
Ensure ForEach uses stable identity (see references/list-patterns.md)
Suggest image downsampling when UIImage(data:) is used (as optional optimization, see references/image-optimization.md)
Adopt Liquid Glass only when explicitly requested by the user
3) Implement new SwiftUI feature
Design data flow first: identify owned vs injected state (see references/state-management.md)
Use modern APIs (no deprecated modifiers or patterns, see references/modern-apis.md)
Use @Observable for shared state (with @MainActor if not using default actor isolation)
Structure views for optimal diffing (extract subviews early, keep views small, see references/view-structure.md)
Reviews SwiftUI code for best practices on modern APIs, maintainability, and performance. This skill should be used when the user asks to review SwiftUI code, check for deprecated iOS/macOS APIs, validate data flow patterns, or audit accessibility compliance in Swift projects.
Validates system integration before deployment. Use when checking ports, database connections, frontend-backend APIs, or debugging blocked/stuck workflows. Detects dead ends, bottlenecks, circular dependencies.