Is there a view/function-builder for CoreData?

[This may be more appropriate for Apple’s developer forums.]

We can use function builders (or whatever we’re calling them now) to set up views with SwiftUI. I was glancing through the CoreData docs. I saw that CoreData models are usually designed with a GUI tool in Xcode. But the description is available as a NSObject class, and technically can be built in code. (It’s like using Auto-Layout in Storyboards/XIBs/NIBs vs. writing them in code.) I wonder if there is already a library out there that lets users write CD models in code with function builders. If not, is it even possible? (I think so.)

Function builders (now Result builders) are a bit overkill for this, and a lot of ORM mechanisms are complicated to express as Result builders (ex: Relationships)

Instead, you might want to consider that Property Wrappers are better for this use case. There are some libraries out there that already do this (ex: https://github.com/JohnEstropia/CoreStore#type-safe-corestoreobjects)

Terms of Service

Privacy Policy

Cookie Policy