From the course: iOS Development Tips

Unlock this course with a free trial

Join today to access over 24,000 courses taught by industry experts.

Swfit UI binding in lists

Swfit UI binding in lists

- [Instructor] There's been a very subtle but important change to lists and other collection views in SwiftUI that makes life a lot easier. Let's take a look at how you use binding differently in these collections. So I have an app here, which I'll start up here in the preview and it works great in SwiftUI, and it's for iOS 14. And you can click on a bunch of buttons here and the check marks will show up the symbols on the top here. Like that. And that's working great if we're doing it for 14.0. But let's take a look at the code a little more carefully here. And we're going to go into ListView and ListView here is built on a model that we have a model up top that's binding and that binding model, you couldn't pass through the for each. And the big change is that you can now do that. So what I have here is because I couldn't send a binding through this correctly. I had to, first of all, make a count, make…

Contents