Skip to content

Instantly share code, notes, and snippets.

@nanlabsweb
Last active February 5, 2018 14:45
Show Gist options
  • Save nanlabsweb/3eb476d97ec7358b4ef67b28bf723eac to your computer and use it in GitHub Desktop.
Save nanlabsweb/3eb476d97ec7358b4ef67b28bf723eac to your computer and use it in GitHub Desktop.
Activity delegates decision to ViewModel. ViewModel creates Intents.
// ...
override fun onCreate(savedInstanceState: Bundle?) {
// ...
createContentButton.setOnClickListener({
startActivity(authViewModel.getActionIntent())
})
// ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment