Created
March 4, 2015 13:25
-
-
Save ivangodfather/ec13b309afc009930320 to your computer and use it in GitHub Desktop.
This file contains 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
1: | |
class ViewController: UIViewController { | |
override func loadView() { | |
view = NSBundle.mainBundle().loadNibNamed("View", owner: self, options: nil).first! as UIView | |
} | |
} | |
2: | |
class ViewController: UIViewController { | |
override func viewDidLoad() { | |
super.viewDidLoad() | |
view.addSubview(NSBundle.mainBundle().loadNibNamed("View", owner: self, options: nil).first! as UIView) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment