SwiftData for the CRUD operations in Local App.

Hi

I have an App that uses SwiftData + CloudKit as a private database to sync across users' devices. Is there a way to enable sharing and collaboration capabilities with other users by using Cloudkit + CoreData? To reduce the complexity of the Shared Object Graph, I envision treating the object graph as an Object (Document). In this way, the cloud's implementation of the sharing DB is simplified. The App will take care of the integrity and security of the document. Ideally, I would love this capability in a multi-peer-to-peer local network, but I have yet to find a Conflict-free Replicated Document library to use.

In summary, I want to use SwiftData for the CRUD operations in the data objects running in the local App and treat the Object Graph as a document for sharing with other users.

Any guidance or any code examples will be appreciated.

Thank you!

SwiftData for the CRUD operations in Local App.
 
 
Q