Skip to content

Instantly share code, notes, and snippets.

View BLCKBIRDS's full-sized avatar

BLCKBIRDS BLCKBIRDS

View GitHub Profile
import SwiftUI
struct ContentView : View {
var body: some View {
HStack {
Text("ADD TO CART")
.font(.custom("Avenir-Medium", size: 20))
.foregroundColor(.black)
Image(systemName: "cart")
.foregroundColor(.black)
struct ContentView : View {
var body: some View {
HStack {
Text("ADD TO CART")
.font(.custom("Avenir-Medium", size: 20))
.foregroundColor(.black)
Image(systemName: "cart")
.foregroundColor(.black)
}
.frame(width: 220, height: 30)
import SwiftUI
struct ContentView : View {
var body: some View {
Button(action: {print("Button touched!")}) {
HStack {
Text("ADD TO CART")
.font(.custom("Avenir-Medium", size: 20))
.foregroundColor(.black)
Image(systemName: "cart")
struct ContentView : View {
var body: some View {
VStack {
}
}
}
struct ContentView : View {
var body: some View {
VStack {
Text("Welcome!")
.font(.largeTitle)
.fontWeight(.semibold)
.padding(.bottom, 20)
}
}
}
struct ContentView : View {
var body: some View {
VStack {
WelcomeText()
Image("userImage")
}
}
}
struct ContentView : View {
var body: some View {
VStack {
WelcomeText()
Image("userImage")
.resizable()
.aspectRatio(contentMode: .fill)
.frame(width: 150, height: 150)
.clipped()
.cornerRadius(150)
import SwiftUI
struct ContentView : View {
var body: some View {
VStack {
WelcomeText()
UserImage()
TextField(title:, text:)
}
}
struct ContentView : View {
var username: String = “"
var body: some View {
VStack {
WelcomeText()
UserImage()
TextField(title:, text:)
struct ContentView : View {
@State var username: String = “"
var body: some View {
VStack {
//...
}
}