swiftui-debugging
Installation
SKILL.md
SwiftUI Debugging
Use this skill to turn SwiftUI performance complaints into a small evidence loop: identify what changed, confirm whether SwiftUI is recreating or merely re-evaluating views, then apply the narrowest fix.
Workflow
-
Reproduce or localize the symptom.
- Search for the named view, model, list/grid, or modifier chain before editing.
- Ask for a minimal reproduction only when the target view or interaction cannot be inferred from the repo.
- Prefer a profiler trace,
_printChanges()output, Console logs, or a clear interaction path over guesswork.
-
Choose the diagnostic path.
- Unexpected body calls or noisy
_printChanges(): readreferences/body-reevaluation.md. - State resets, repeated
onAppear, weird animations, focus loss, or scroll resets: readreferences/view-identity.md. - Slow lists, grids, scroll views, or initial load with many items: read
references/lazy-loading.md. AnyView, object creation inbody, expensive sorting/filtering, oversized images, or repeated state writes: readreferences/common-pitfalls.md.
- Unexpected body calls or noisy