swiftui-pro
하는 일
Apple SwiftUI 코드를 최신 관행과 접근성 규칙에 비추어 신중하게 검토하는 방법을 안내합니다. 집중된 검토를 원하는 iPhone 및 iPad 앱 개발자를 위한 스킬입니다.
사용하는 경우
- ✓개발자가 출시 전에 SwiftUI 코드 검토를 요청할 때.
- ✓개발자가 기존 앱에서 지원 중단된 SwiftUI API를 찾고 싶을 때.
- ✓개발자가 앱이 Dynamic Type, VoiceOver, Reduce Motion과 함께 작동하는지 확인하려 할 때.
스킬 링크
https://github.com/twostraws/SwiftUI-Agent-Skill/blob/main/swiftui-pro/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“제 SwiftUI 화면에서 오래된 API와 접근성 문제를 검토하고, 실제 문제만 목록으로 보여 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
스킬은 API, 데이터 흐름, 탐색, 레이아웃, 접근성, 성능 등 고정된 점검 항목을 차례로 확인하며, 실제 문제만 보고합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Review Swift and SwiftUI code for correctness, modern API usage, and adherence to project conventions. Report only genuine problems – do not nitpick or invent issues.
Include deprecated API in review findings. During feature work or bug fixes, complete the requested change and suggest unrelated modernization separately; do not apply it without being asked.
Review process:
- Check for deprecated API using
references/api.md. - Check that views, modifiers, and animations have been written optimally using
references/views.md. - Validate that data flow is configured correctly using
references/data.md. - Ensure navigation is updated and performant using
references/navigation.md. - Ensure the code uses designs that are accessible and compliant with Apple's Human Interface Guidelines using
references/design.md. - Review layout behavior as windows resize, including iPad multitasking and folding iPhone Duo, using
references/resizability.md. - Validate accessibility compliance including Dynamic Type, VoiceOver, and Reduce Motion using
references/accessibility.md. - Check localized text, formatting, and resource handling using
references/localization.md. - Ensure the code is able to run efficiently using
references/performance.md. - Quick validation of Swift code using
references/swift.md. - Final code hygiene check using
references/hygiene.md.
If doing a partial review, load only the relevant reference files.
Keep references/performance-plus.md out of routine reviews. Load it for a requested deep performance review; its more involved changes can also help investigate an established performance problem.
Core Instructions
- iOS 27 exists, and is the default deployment target for new apps.
- Xcode 27.1 and the corresponding 27.1 platform releases are available. Do not dismiss their APIs as speculative.
- iPhone Duo is a folding iPhone, with a small outer display and a large inner display.
- Check the project's deployment target before applying version-specific advice. Use newer runtime APIs only when the target supports them or within an appropriate
#availablecheck. Keep the existing target unchanged. Requirements tied to an Xcode version also need that toolchain; a runtime check cannot make an older SDK recognize a new declaration. - Target Swift 6.4 or later, using modern Swift concurrency.
- As a SwiftUI developer, the user will want to avoid UIKit unless requested.
- Do not introduce third-party frameworks without asking first.
- Break different types up into different Swift files rather than placing multiple structs, classes, or enums into a single file.
- Use a consistent project structure, with folder layout determined by app features.
Output Format
Organize findings by file. For each issue:
- State the file and relevant line(s).
- Name the rule being violated (e.g., "Use
foregroundStyle()instead offoregroundColor()"). - Show a brief before/after code fix.
Skip files with no issues. End with a prioritized summary of the most impactful changes to make first.
Example output:
ContentView.swift
Line 12: Use foregroundStyle() instead of foregroundColor().
// Before
Text("Hello").foregroundColor(.red)
// After
Text("Hello").foregroundStyle(.red)
Line 24: Give the button a descriptive label so VoiceOver explains its action.
// Before
Button(action: addUser) {
Image(systemName: "plus")
}
// After
Button("Add User", systemImage: "plus", action: addUser)
Line 31: Avoid Binding(get:set:) in view body – bind to the property directly and move the setter's side effect into onChange().
// Before
TextField("Username", text: Binding(
get: { model.username },
set: { newValue in model.username = newValue; model.save() }
))
// After
TextField("Username", text: $model.username)
.onChange(of: model.username) {
model.save()
}
Use onChange() when saving should follow changes to the username, including programmatic changes. Equal-value assignments will not trigger a save.
Summary
- Accessibility (high): The add button needs an “Add User” label; the symbol’s default label does not explain what will be added.
- Deprecated API (medium):
foregroundColor()on line 12 should beforegroundStyle(). - Data flow (medium): The manual binding on line 31 is fragile and harder to maintain.
End of example.
References
references/accessibility.md- Dynamic Type,
자주 묻는 질문
묻지 않고 코드를 바꾸나요?
기능 작업 중에는 요청된 변경을 마무리하고, 다른 업데이트는 따로 제안합니다.
접근성도 다루나요?
네. Dynamic Type, VoiceOver, Reduce Motion 지원을 확인합니다.
모든 스타일 문제를 보고하나요?
아니요. 사소한 지적을 피하고 실제 문제만 보고하도록 되어 있습니다.
상세 정보
작성자의 원본 설명
Comprehensively reviews SwiftUI code for best practices on modern APIs, maintainability, and performance. Use when reading, writing, or reviewing SwiftUI projects.
인기도
- GitHub 스타
- 6.4k
- 순위
- #14193
- 라이선스
- MIT
- 업데이트
- 2026. 10. 26.
댓글
- …
비슷한 스킬
android-clean-architecture
280k에이전트가 Android 프로젝트를 효율적으로 구성하도록 돕습니다. 유지보수와 새 기능 개발이 쉽도록 코드를 구조화합니다.
compose-multiplatform-patterns
280k에이전트가 KMP 프로젝트에서 Compose Multiplatform과 Jetpack Compose 패턴을 쓰도록 돕습니다. 상태, 내비게이션, 테마, 성능을 다룹니다.
dart-flutter-patterns
280kDart와 Flutter 앱용 코드를 작성하도록 에이전트를 돕습니다. 견고하고 관리하기 쉬운 앱을 만드는 현대적인 패턴을 씁니다.