During OC development I used a third-party AutoLayout library called Masonry, and after turning to Swift found that although Swift can be mixed OC, but always feel a bit of trouble, found on GitHub, this is called Snapkit third-party library, found to use more convenient, Share with you
1. Download Snapkit on GitHub, choose iOS target Compilation (command+b), find Snapkit.framework
2. Right button "Show in Finder"
3. Drag this file into our project
4, two places to set up
5, then we can shameless not the same in swift convenient use of this kind of masonry third-party library!
Isn't it convenient?
Tips:
The downloaded Snapkit has a codesnippets folder that copies the contents of the
~/library/developer/xcode/userdata/codesnippets
That can be quickly constructed Snapkit AutoLayout structural template, improve the development efficiency!
REF:
http://snapkit.io/docs/
Http://mobile.51cto.com/hot-431722.htm
Http://www.cocoachina.com/industry/20130604/6336.html
Masonry third-party libraries in Swift--snapkit