Skip to content

Latest commit

 

History

History
29 lines (20 loc) · 509 Bytes

README.md

File metadata and controls

29 lines (20 loc) · 509 Bytes

Toggle

A control that toggles between on and off states.

import SwiftUI

struct ContentView: View {
    
    @State private var vibrateOnRing = true

    var body: some View {
        Toggle("Vibrate on Ring", isOn: $vibrateOnRing)
            .padding()
    }
}

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

Links that help