Skip to content

Instantly share code, notes, and snippets.

@rockbruno
Created September 13, 2018 18:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rockbruno/4cf88fe207fdcccf6dcd259ac3710eb3 to your computer and use it in GitHub Desktop.
Save rockbruno/4cf88fe207fdcccf6dcd259ac3710eb3 to your computer and use it in GitHub Desktop.
final class MyViewController: UIViewController {
   
let myView = MyView()
 
override func viewDidLoad() {
super.viewDidLoad()
setupMyView()
}
 
private func setupMyView() {
view.addSubview(myView)
//Umas 10 linhas de constraints
myView.delegate = self
//Agora temos tanto a 'view' quanto a 'myView'...
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment