It requires Xcode 8.0+ and Swift 3.0.
Your project deployment target must be iOS 8.0+
OCExtensions is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'OCExtensions'
// Get an image representation from a color.
// Default size: 1x1px
func image(withSize size: CGSize? = nil) -> UIImage?
// Example
let redImage = UIColor.redColor().image()
// Instantiate an image with a color.
// Default size: 1x1px
convenience init?(color: UIColor, size: CGSize? = nil)
// Example
let redImage = UIImage(color: UIColor.redColor())
// Returns a non-optional String value.
var textValue: String
// Check if text input is empty.
var isEmpty: Bool
// Intantiate a Gradient Layer passing only the frame, orientation and color array
convenience init(frame: CGRect, orientation: GradientOrientation, colors: [CGColor])
// TODO: documentation
// TODO: documentation
// TODO: documentation
Henrique Morbin, morbin_@hotmail.com
OCExtensions is available under the MIT license. See the LICENSE file for more info.