SwiftUI Core Data save single values

Hello

I am using CoreData in my App and want to save a single Picker value. I could create an entity with an Integer attribute and always edit the first object in the EntityList. But that doesn't sound like a clean solution. The Picker is placed inside a settings view and has to be synced with iCloud. Is there a simple way to do this?

Thank You

Answered by OOPer in 692663022

But that doesn't sound like a clean solution. 

Why do you think so? That sounds like the right solution for me.

Accepted Answer

But that doesn't sound like a clean solution. 

Why do you think so? That sounds like the right solution for me.

SwiftUI Core Data save single values
 
 
Q