I found a workaround for this that is similar to other workarounds for enums where you store the data in a private property and have a computed property that gets and sets it using the type you really wanted to use. My stored property is a string and my computed property encodes and decodes to and from json. I assume this is essentially what SwiftData itself will do when they finally add support for enums with associated values.
Post
Replies
Boosts
Views
Activity
Multiline
Remove .modelContainer(for: Card.self) the container for the document is set automatically by DocumentGroup.
BlockQuote
That code gets removed when they have you split up the Scene builder by platform. It seems like the data is just stuck on disk with no way to tell where it is or clear it out.
Same issue here. Not sure how I''m even supposed to figure out where on disk this data is going. Really wish Apple would provide more help with this stuff.
Thanks for the help fixing the preview, however I'm hitting issues when running the app in the simulator. Maybe something isn't setup right for working with the backend? Getting these errors when trying to create a new file in the running app:
os_unix.c:46973: (0) open(/Users/myUserName/Library/Developer/CoreSimulator/Devices/17277B7F-0589-4D47-B3BF-C4C910FC23D6/data/Containers/Data/Application/C4A2EDA5-4BD0-4D9C-8437-75DFEC2B269F/Library/Application Support/default.store) - Undefined error: 0
API call with unopened database connection pointer
misuse at line 179760 of [554764a6e7]