From the course: Introducing App Development for iOS 14

Unlock the full course today

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

SwiftUI stacks

SwiftUI stacks

From the course: Introducing App Development for iOS 14

Start my 1-month free trial

SwiftUI stacks

- [Instructor] Now I want you to recall how the app is supposed to look. So we're building a tip calculator and the layout is generally vertical. So you have the title at the top, and then you have the money that you're putting in the text field, the slider, and then below that you have the total. So, what we're going to do is create the really basic layout of this and for things that we haven't talked about much yet in the course, we're going to put placeholder user interface items there. So here we have this hello world text, and you can see that it has something called padding with it. We're going to look at padding a little bit later on. So let's say we want to make a stack of vertical items. We can do that using something called a VStack. Now if you're new to programming, it's really important to note these curly braces. So each set of curly braces is part of something. So if I look at this block right here, so…

Contents