Popular Destination Details and Text Fix
SwiftUI Mastery Travel Discovery
In this section of the course, we're ready to move onto rendering out details for Popular Destinations. This screen contains a lot of components so for today's lesson we'll start off easy by just laying out the foundation of our UI. Something that will be tricky is to address the Text component's layout issues with embedded alongside a resizable Image inside a ScrollView.

Comments (1)
johnniefujita
2 years ago
Mr. Voong, i have huge respect for your work and have been coding for iOS with much more confidence, since i discover your lessons back from the UIKit days. If i may say, i've solved this in a definitive fashion, using GeometryReader. GeometryReader { geometry in Image(<imagename>).resizable() .scaledToFill() .frame(width: geometry.size.width, height:<someHeight>) .clipped() } knowing you, you probably already know that, only haven't got the time to update it. I hope some other student can benefit from this comment.
johnniefujita
2 years ago
also maybe you know some pitfall of this method. That i may not be aware about. thanks
Brian Voong
2 years ago
johnniefujita
2 years ago
Thanks Mr. Voong. Always very precise and insightful.
HELP & SUPPORT