Created
May 1, 2017 23:18
-
-
Save shanev/4bc155c076d8a90abaff8d4c78a1637e 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
import UIKit | |
public class ViewController<T>: UIViewController { | |
var viewModel: T! | |
override public func viewDidLoad() { | |
super.viewDidLoad() | |
assertViewModel() | |
} | |
} | |
private extension ViewController { | |
func assertViewModel() { | |
assert(viewModel != nil) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment