Skip to content

A Swift extension on UIView to easily add borders to text fields or labels

Notifications You must be signed in to change notification settings

gustanas/SwiftBorders

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

SwiftBorders

A Swift extension on UIView to easily add borders to text fields or labels

How to use it?

  • Add Borders.swift to your project
  • Add the borders in viewDidLayoutSubviews method, you can optionally define the color. For example:
override func viewDidLayoutSubviews() {
    phoneNumberTextField.addBorder(.bottom)
    countryCodeLabel.addBorder(.right)
    countryCodeLabel.addBorder(.bottom)
}  

Result:

Screenshot

Twitter: @gusta_nas

Website: gustanas.co

About

A Swift extension on UIView to easily add borders to text fields or labels

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages