Created
September 13, 2022 10:52
-
-
Save betty-godier/db2c01b6ce8b9047ef742599f1f57782 to your computer and use it in GitHub Desktop.
Creation of the construction of the view , ScrollView, VStack
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import SwiftUI | |
struct ContentView: View { | |
private var currentSymbol: String? | |
private var conditions: String? | |
var body: some View { | |
ScrollView { | |
VStack { | |
if let currentSymbol { | |
Image(systemName: currentSymbol) | |
.font(.system(size: 200, weight: .light)) | |
} | |
if let conditions { | |
Text(conditions) | |
.font(.title) | |
} | |
} | |
.frame(maxWidth: .infinity) | |
} | |
} | |
} | |
struct ContentView_Previews: PreviewProvider { | |
static var previews: some View { | |
ContentView() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment