Published On Apr 15, 2021
In the last video in this series, we learned how to implement Core Data into SwiftUI applications using @FetchRequest. Although that method is more "SwiftUI", it's not always practical to use in production applications. In this video we will learn an alternative approach and connect Core Data to our app using a ViewModel in MVVM (Model-View-ViewModel architecture). As you'll see, the main benefit to this method is that we can separate our code so that the code relating to updating Core Data is totally separate from the code relating to the View (the UI).
If you've watched both videos... which method do you prefer?
Leave a comment below :)
Next video: • Core Data relationships, predicates, ...
Last video: • How to use Core Data with @FetchReque...