swiftui-specialist — Claude Code skill: SwiftUI patterns
A skill that feeds an AI agent reference notes on idiomatic SwiftUI while it writes, reviews or edits your code.
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a claude-codeWhat swiftui-specialist does
The skill is a set of reference files. references/structure.md covers when to split a section into its own View struct versus a computed property, what init costs look like, and why a single-child Group is an anti-pattern. references/dataflow.md handles passing and storing data: @State, @Binding, @Observable models instead of ObservableObject, the @MainActor and Equatable requirements, and the granularity traps of per-property observation.
Other files cover @Environment and EnvironmentKey, conditional modifiers, localizing user-facing text, custom Animatable types, and ForEach. Two more are about soft-deprecated SwiftUI APIs: one explains how to spot them and when to migrate, the other is a searchable list with replacements.
Ask for a broad review of a large codebase and the agent scans the project first, splits it into smaller areas, and offers them for evaluation one at a time; a full review runs off a TODO list. One thing to know: the skill states its content overrides whatever the model previously learned about SwiftUI, so on contested points the agent follows these references instead of its own memory.
What it helps with
- split a crowded screen into separate
Viewstructs without extra computed properties - migrate a model from
ObservableObjectto@Observablewithout losing observation - find soft-deprecated SwiftUI APIs in a project and swap them out
- check element identity in
ForEachandListso animations keep working - move user-facing strings into localization with correct date and number formats
Example prompts for the agent
- Review this screen against
references/structure.md— should these sections be separateViewstructs? - Rewrite this model with
@Observableand explain what changes in property observation - Find soft-deprecated SwiftUI APIs in this project and suggest replacements
How to install swiftui-specialist
1Skills CLI (Vercel)
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a claude-code2Manually: put the files in place
~/.claude/skills/swiftui-specialist/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/swiftui-specialist/
1Skills CLI (Vercel)
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a codex2Manually: put the files in place
.agents/skills/swiftui-specialist/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a cursor2Manually: put the files in place
.cursor/skills/swiftui-specialist/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install superagents-lab/xcode27-skills swiftui-specialist2Manually: put the files in place
.github/skills/swiftui-specialist/SKILL.md1Skills CLI (Vercel)
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a gemini-cli2Platform CLI
gemini skills install https://github.com/superagents-lab/xcode27-skills --path swiftui-specialistManually: put the files in place
.devin/skills/swiftui-specialist/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about swiftui-specialist
How do I install swiftui-specialist in Claude?
Run npx skills add superagents-lab/xcode27-skills --skill swiftui-specialist -a claude-code. The skill lands at ~/.claude/skills/swiftui-specialist/SKILL.md.
What does swiftui-specialist do?
It gives the agent references on view structure, data flow, environment, modifiers, localization, animations and ForEach. The agent consults them while writing, reviewing or editing SwiftUI code.
How is this different from what the model already knows about SwiftUI?
The skill declares its material takes precedence over the model's prior training on the topic. In practice, when the two disagree, the agent follows the skill's references.