Ray Wenderlich Course - SwiftUI (Part 3)
Cracking on with SwiftUI! As I've said, this has been a tricky course but I'm learning plenty. Let's continue! Start Time - 19:55 Slider and Stepper Stepper - plus or minus a value (buttons for this) Slider - as with bullseye State - use of @State and the $ symbol. struct ContentView : View { @ State private var orderCount = 0 var body : some View { VStack { Stepper (onIncrement: { self . orderCount += 1 } , onDecrement: { }) { Text ( "Set order amount" ) } } } } A bit about state - this is a value that can change and will update accordingly. So this is a lot easier! Stepper ( "Set order amount" , value: $orderCount) Slider (value: $houseTemperature , in: ( 30 ... 1...