0PricingLogin
SwiftUI Academy · Lesson

Stacking Views Vertically

Group views top to bottom with VStack.

Why You Need Stacks

A SwiftUI body can return only one view. To show several views together, you wrap them in a container that arranges them for you. 📦

Meet VStack

A VStack stacks its child views vertically, top to bottom. It is your go-to container for column-style layouts like a title above a subtitle.

All lessons in this course

  1. Stacking Views Vertically
  2. Rows with HStack
  3. Layering with ZStack
  4. Spacing & Alignment in Stacks
← Back to SwiftUI Academy