Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 1.54 KB

README.md

File metadata and controls

49 lines (35 loc) · 1.54 KB

GSToggleSwitch

CI Status Version License Platform

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

GSToggleSwitch is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'GSToggleSwitch', '~> 0.3'

Easy to Use

You can simply set all the properties in simple way

       toggleSwitch.set(
          properties: { prop in
              prop.width = 40
              prop.height = 20
              prop.cornerRadius = 10
              prop.onBackgroundColor = .green
              prop.thumbProperties.showThumbShadow = true
              prop.thumbProperties.backgroundColor = .white
          },
          tapOnSwitch: { [weak self] in
              guard let self = self else { return .off }
              return self.toggle1.currentState
          }
      )

Author

Gaganjot Singh([email protected])

License

GSToggleSwitch is available under the MIT license. See the LICENSE file for more info.