TextAttributes provides simple to use API for setting text attributes for common UIKit components.
TextAttributes allow you to forget about chunky NSAttributedString API == you don’t have to remember the [NSAttributedStringKey: Any] or it’s consecutive string keys (.font, .foregroundColor, .kern) and rather focus directly on styling.
Usage
let textAttributes = TextAttributes.attributes(font: Font.normalRegular, color: Color.white)
TextAttributes
TextAttributes provides simple to use API for setting text attributes for common UIKit components.
TextAttributes allow you to forget about chunky
NSAttributedString
API == you don’t have to remember the [NSAttributedStringKey: Any] or it’s consecutive string keys (.font
,.foregroundColor
,.kern
) and rather focus directly on styling.Usage
UILabel
UIButton
UITextView
Cocoapods
Add source