From the course: Complete Guide to SwiftUI

Unlock this course with a free trial

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

Add navigation

Add navigation

- [Instructor] We got the ingredients in place and it's time to add the recipes. As I'm running these as independent views, tab views makes sense to navigate between them. So let's head over to Main here, and we can close up Ingredients, and we can head over here to Content View. And we can see what's going on here. Couple things to start with is the source of all our models. You can see right here we've got the bindable ingredients and we have two State variables for Recipes and RecipeSteps. Again, all of these are observable, so I can just go straight into stuff from state and bindable, but why did I put this one as bindable? Let's go over one step over here to Davids Grinds app. And you can see in here I made this an environment. So we have an environment variable here set up. So I made the state variable here and then I said this content view here, I'm going to make this environment. So, but I'm going to go back into environment here. I started it as bindable, but there are places…

Contents