I still haven't figured out why this is happening. I'm moving forward with manually updating the arrays but would still like to understand if the SwiftData changes to the array are supposed to be picked up by SwiftUI. If so, then I can file a bug but I'm not sure how to tell if this is expected behavior or not.
Post
Replies
Boosts
Views
Activity
it looks like I had left some test code in my List example I initially provided. The below code is what I'm actually using (no online filtering, I'm using the computed property) For the user todo lists section.
// MARK: -- User TodoLists
Section(header: Text("Lists").padding(.top, -24)) {
ForEach(userTodoLists) { list in
NavigationLink(value: list) {
Text(list.name)
}
}
}
}
I forgot to mention what my model looked like. A simplified version of it looks like this:
@Model class FMList {
var listID: UUID
var name: String
var isFavorite: Bool
// init func omitted for brevity
}