Created
February 4, 2018 20:17
-
-
Save twittemb/b7f8b107b1c588afcc077bc4f9b42564 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
| extension ViewModelBased where Self: StoryboardBased & UIViewController { | |
| static func instantiate (with viewModel: ViewModel) -> Self { | |
| let viewController = Self.instantiate() | |
| viewController.viewModel = viewModel | |
| return viewController | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment