SwiftUI: Difference between revisions

From Chorke Wiki
Jump to navigation Jump to search
Line 95: Line 95:
* [https://stackoverflow.com/questions/56760335 SwiftUI Round Specific Corners]
* [https://stackoverflow.com/questions/56760335 SwiftUI Round Specific Corners]
* [https://stackoverflow.com/questions/26028918 iPhone/iPad Device Model]
* [https://stackoverflow.com/questions/26028918 iPhone/iPad Device Model]
* [https://github.com/SimpleBoilerplates/SwiftUI-Cheat-Sheet SwiftUI Cheat Sheet]


|}
|}

Revision as of 04:00, 10 February 2020

ContentView

import SwiftUI

struct ContentView: View {
    var body: some View {
        VStack(alignment: .leading) {
            Text("Turtle Rock")
                .font(.title)
            HStack {
                Text("Joshua Tree National Park")
                    .font(.subheadline)
                Spacer()
                Text("California")
                    .font(.subheadline)
            }
        }
        .padding()
    }
}

struct ContentView_Preview: PreviewProvider {
    static var previews: some View {
        ContentView()
    }
}

References