๐ฐconditional modifier
SwiftUI โฉ view โฉ modifier โฉ conditional modifier
Change view modifiers conditionally
Circle()
// โญ๏ธ conditional modifier (`isOn`: @State view property)
.foregroundColor( isOn ? .red : .yellow )
ternary conditional operator ( a ? b : c)
Last updated
Was this helpful?