CloudKit, iCloud containers, sharing, and sync
CloudKit can provide Apple-account-backed storage and sharing, but it does not remove synchronization design. Local truth, pending operations, stable identity, retry, conflict, and account transitions still need explicit owners.
Design the capability
- Keep CloudKit records and zones in an adapter. Domain notes do not import CloudKit types.
- Map signed out, unavailable, restricted, quota, network, partial, and server-change states into recoverable product behavior.
- Use record versions and deterministic conflict policy. Preserve both user edits when automatic merge is unsafe.
- Sharing needs participant roles, revocation, invitation handling, and local visibility updates.
Validation boundary
No iCloud container, entitlement, schema deployment, Apple account, share invitation, network sync, or device run occurred.
Series navigation
- Previous: Part 98: App Intents, Shortcuts, Spotlight, and system actions
- Next: Part 100: MapKit, Core Location, geocoding, and WeatherKit
- Series index: Zero to iOS Hero