From the course: iOS 14 Development Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Creating detail views

Creating detail views

From the course: iOS 14 Development Essential Training

Start my 1-month free trial

Creating detail views

- [Instructor] Our next step is to make this interactive. What we want to do, is make it so when you click on any of these items you go to a view to see detailed information. For now we're just going to create that second view and transition to it. To create the view, you may remember we can just create a new SwiftUI view with command + N under iOS user interface choose SwiftUI view and hit next. Let's save this as DetailView and then hit return to create the file. Let's leave this as is for now and head back over to content view. In our content view we're going to make a simple change. We're going to take this text object and cut it with command + X and inside of here in the list type navigation link with capital L. The code ending says a view that controls navigation presentation. Open up the parentheses there and the one that you want is the title and destination. The title is going to be object.title and the…

Contents