© Bear Cahill 2021
B. CahillUI Design for iOS App Developmenthttps://doi.org/10.1007/978-1-4842-6449-2_5

5. ObservableObjects

Bear Cahill1  
(1)
Denton, TX, USA
 

In the previous chapters, we’ve used isolated properties for values. But in development we usually have more complex models. We typically deal with structs or classes that have multiple properties representing our data.

In this chapter, we’ll look at how to observe property updates of reference type objects. When the properties change, the UI will be notified and updated.

To accomplish this, we’ll use aspects of the Combine framework. We’ll go into more detail of that framework in a later chapter. For now, we’ll see how it works for our purposes of binding.

We will continue to work in our same ...

Get UI Design for iOS App Development: Using SwiftUI now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.