Latest1.0.0
Homepagehttps://github.com/hoangta/Oneline
LicenseMIT
Platformsios 8.0
Authors

Language License Platform Pod Version

How to use

Initialize UIView then chain setting its properties.

let label = UILabel("Hi, there!").font(.systemFont(ofSize: 12)).color(.blue).lines().bgColor(.green).align(.center)

Instead of

let label = UILabel()
label.text = "Hi, there!"
label.font = .systemFont(ofSize: 12)
label.textColor = .blue
label.numberOfLines = 0
label.backgroundColor = .green
label.textAlignment = .center

Cocoapods

Add the following entry in your Podfile

pod 'Oneline'

Then run pod install.

Contribution

Feel free to fork, pull to request for your commonly used UIView subclasses.

License

Oneline is released under an MIT license.

Latest podspec

{
    "name": "Oneline",
    "version": "1.0.0",
    "summary": "Set common views' properties in a condensed way - single line.",
    "homepage": "https://github.com/hoangta/Oneline",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Hoang Ta": "[email protected]"
    },
    "source": {
        "git": "https://github.com/hoangta/Oneline.git",
        "tag": "1.0.0"
    },
    "source_files": "Oneline/Classes/*.swift",
    "platforms": {
        "ios": "8.0"
    }
}

Pin It on Pinterest

Share This