Last active
March 14, 2017 08:33
-
-
Save nakiostudio/51dfbeaff68291a6415bac9de7ad9c76 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Never tried to run this code so expect compilation | |
// issues | |
func viewDidLoad() { | |
super.viewDidLoad() | |
// ScrollView | |
self.view.addSubview(self.scrollView) | |
self.scrollView <- Edges(0.0) | |
// CollectionView | |
self.scrollView.addSubview(self.collectionView) | |
self.collectionView <- [ | |
Size(0.0).like(self.scrollView), | |
Left(0.0).to(self.scrollView, .left), | |
Top(0.0).to(self.scrollView, .top), | |
Bottom(0.0).to(self.scrollView, .bottom) | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment