Created
August 1, 2021 21:33
-
-
Save sergenes/450e669d105f93a43a13670e05a59cc6 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
private fun onAction( action: ListScreenActions, | |
runBefore: () -> Unit = {}, | |
runAfter: () -> Unit = {} | |
) { | |
if (state() == action.source) { | |
runBefore() | |
screenState.value = action.target | |
runAfter() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment