Post

Replies

Boosts

Views

Activity

Comment on SwiftUI SwiftData Previews not working as expected
Still the case in Beta 6. I also would like to mention, that this is the case for every View (including ContentView), in contrast to @mrhanlon situation. Another thing note mentioning is that using the previewData as the modelContainer for the app (running on my iPhone) just works fine. However replacing the new Preview macro with the old preview code does not resolve the issue. So the issue must be Preview related, independent from the new macro.
Aug ’23