CocoaPods trunk is moving to be read-only. Read more on the blog, there are 3 months to go.

OCExtensions 1.10.2

OCExtensions 1.10.2

TestsTested ✗
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Sep 2017
SwiftSwift Version 3.0
SPMSupports SPM ✗

Maintained by Morbix, Cristian Madrid.



OCExtensions


Build Status


Requirements

It requires Xcode 8.0+ and Swift 3.0.

Your project deployment target must be iOS 8.0+

Installation

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

pod 'OCExtensions'

Documentation

Color

// Get an image representation from a color.
// Default size: 1x1px
func image(withSize size: CGSize? = nil) -> UIImage?

// Example
let redImage = UIColor.redColor().image()

Image

// Instantiate an image with a color.
// Default size: 1x1px
convenience init?(color: UIColor, size: CGSize? = nil)

// Example
let redImage = UIImage(color: UIColor.redColor())

TextField

// Returns a non-optional String value.
var textValue: String

// Check if text input is empty.
var isEmpty: Bool

Layer

// Intantiate a Gradient Layer passing only the frame, orientation and color array
convenience init(frame: CGRect, orientation: GradientOrientation, colors: [CGColor])

View

// TODO: documentation

Badge

// TODO: documentation

ViewController

// TODO: documentation

Author

Henrique Morbin, [email protected]

License

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