I have been fiddling with CloudKit for some time now, but I can't find a real-life example for how to use CKRecordZone. I understand their capabilities (namely, grouping records, especially for subscriptions), but does someone have a real experience of having used them, and to map which concept ?
Thanks
The Apple News app uses two zones in the private database for the user's information: ReadingList and ReadingHistory. ReadingList stores news article IDs that have been bookmarked; ReadingHistory stores news article IDs that have been read. By separating the article IDs into two different zones it allows them to be efficiently synced. For example, if an article is only read on a device (and not bookmarked), then the other device receives a notification that the ReadingHistory zone has changed, then it only has to sync that zone rather than both. For more info, you can read my full write up on the News app's syncing behavior here.
CloudKit record zones give you three main benefits:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With