Created
July 4, 2018 09:13
-
-
Save onmyway133/64e6ddcb7867453ed690a35951477f1e 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
| class ViewModel { | |
| class Input { | |
| let fetch = PublishSubject<()>() | |
| } | |
| class Output { | |
| let friends: Driver<[User]> | |
| } | |
| let apiClient: APIClient | |
| let input: Input | |
| let output: Output | |
| init(apiClient: APIClient) { | |
| self.apiClient = apiClient | |
| // Connect input and output | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment