Creating a Horizontal Stack
A HStack allows you to arrange subviews horizontally.
Customizing Spacing
Use the spacing
parameter to set a custom spacing between subviews of a HStack
.
Customizing Alignment
By default, the HStack's alignment is set to the center. You can set the alignment of subviews in a HStack to top, center, or bottom.
Combined with Vertical Stack
You can nest a HStack into a VStack and vice-versa as they are all views. This allows you to create more complex layouts.