Loading...
Loading...
SwiftData persistence and data-layer architecture for iOS 26 / Swift 6.2 clinic modular MVVM-C apps. Use when writing, reviewing, or refactoring @Model entities, repository implementations, stale-while-revalidate reads, optimistic queued writes, sync/retry behavior, and SwiftUI integration that keeps SwiftData types inside Data-only boundaries.
npx skill4agent add pproenca/dot-skills swift-dataswift-ui-architect┌───────────────────────────────────────────────────────────────┐
│ Feature modules: View + ViewModel, no SwiftData imports │
├───────────────────────────────────────────────────────────────┤
│ Domain: models + repository/coordinator/error protocols │
├───────────────────────────────────────────────────────────────┤
│ Data: @Model entities, SwiftData stores, repository impls, │
│ remote clients, retry executor, sync queue, conflict handling │
└───────────────────────────────────────────────────────────────┘@ModelModelContext@QueryFetchDescriptorDomainDesignSystemDataDependencyContainerDomain*CoordinatingErrorRoutingAppErrorDataAsyncStreamTripFriendmodel-domain-mappingstate-business-logic-placement@Modelmodel-*model-domain-mappingpersist-repository-wrapperModelContainerpersist-container-setuppersist-container-error-recoverystate-dependency-injectionstate-query-vs-viewmodelcrud-*sync-*rel-*preview-*schema-*persist-model-macropersist-container-setuppersist-autosaveschema-configurationquery-background-refreshpersist-model-actorquery-property-wrapperstate-wrapper-viewsschema-unique-attributessync-conflict-resolutionschema-migration-recoverypersist-container-error-recoverycrud-save-error-handlingsync-offline-firstsync-fetch-persistpersist-app-groupschema-configurationstate-query-vs-viewmodelpersist-repository-wrapper| Priority | Category | Impact | Prefix |
|---|---|---|---|
| 1 | Data Modeling | CRITICAL | |
| 2 | Persistence Setup | CRITICAL | |
| 3 | Querying & Filtering | HIGH | |
| 4 | CRUD Operations | HIGH | |
| 5 | Sync & Networking | HIGH | |
| 6 | Relationships | MEDIUM-HIGH | |
| 7 | SwiftUI State Flow | MEDIUM-HIGH | |
| 8 | Schema & Migration | MEDIUM-HIGH | |
| 9 | Sample Data & Previews | MEDIUM | |
model-domain-mappingmodel-custom-typesmodel-class-for-persistencemodel-identifiablemodel-initializermodel-computed-propertiesmodel-defaultsmodel-transientmodel-external-storagepersist-repository-wrapperpersist-model-macropersist-container-setuppersist-container-error-recoverypersist-context-environmentpersist-autosavepersist-enumerate-batchpersist-in-memory-configpersist-app-grouppersist-model-actorpersist-identifier-transferquery-property-wrapperquery-background-refreshquery-sort-descriptorsquery-predicatesquery-dynamic-initquery-fetch-descriptorquery-fetch-tuningquery-localized-searchquery-expressioncrud-insert-contextcrud-delete-indexsetcrud-sheet-creationcrud-cancel-deletecrud-undo-cancelcrud-edit-buttoncrud-dismiss-savecrud-save-error-handlingsync-fetch-persistsync-offline-firstsync-conflict-resolutionrel-optional-singlerel-array-manyrel-inverse-autorel-delete-rulesrel-explicit-sortstate-query-vs-viewmodelstate-business-logic-placementstate-dependency-injectionstate-bindablestate-local-statestate-wrapper-viewsschema-define-all-typesschema-unique-attributesschema-unique-macroschema-indexschema-migration-planschema-migration-recoveryschema-configurationpreview-sample-singletonpreview-in-memorypreview-static-datapreview-main-actor| File | Description |
|---|---|
| references/_sections.md | Category definitions and ordering |
| assets/templates/_template.md | Template for new rules |
| metadata.json | Version and reference information |