skills/guide-swiftdata/SKILL.md
SwiftData patterns — autosave, relationships, dangerous predicates, CloudKit constraints, indexing, class inheritance. Use when writing, reviewing, or debugging SwiftData code.
npx skillsauth add vabole/apple-skills guide-swiftdataInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Guide Skill — This is an expert workflow/pattern guide, not API reference documentation. Originally from twostraws/SwiftData-Agent-Skill by Paul Hudson. MIT License.
Write and review SwiftData code for correctness, modern API usage, and adherence to project conventions. Report only genuine problems — do not nitpick or invent issues.
references/core-rules.md.references/predicates.md.references/cloudkit.md.references/indexing.md.references/class-inheritance.md.If doing partial work, load only the relevant reference files.
| Topic | Reference |
|-------|-----------|
| Autosave, relationships, delete rules, @Query restrictions, #Unique, @Transient | references/core-rules.md |
| Supported predicates, dangerous patterns that crash at runtime, unsupported methods | references/predicates.md |
| CloudKit constraints: no #Unique, optional requirements, eventual consistency | references/cloudkit.md |
| Database indexing (iOS 18+), single and compound property indexes | references/indexing.md |
| Model subclassing (iOS 26+), @available requirements, predicate filtering | references/class-inheritance.md |
development
API reference: XCUITest. Query for element queries, waiting patterns, Swift 6 @MainActor, assertions, screenshots, launch arguments.
development
API reference: TipKit. Tip protocol, TipView, PopoverTipView, Tips.configure, inline and popover tips.
development
API reference: MapKit for SwiftUI. Map view, Marker, Annotation, camera positions, map features.
development
API reference: Apple Human Interface Guidelines. Query for design patterns, UI components, accessibility, color, typography, layout, haptics.