Skip to content

Instantly share code, notes, and snippets.

@raulh82vlc
Created March 1, 2021 12:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save raulh82vlc/7dbb6a621bf85df1d5493abe8bdbd51b to your computer and use it in GitHub Desktop.
Save raulh82vlc/7dbb6a621bf85df1d5493abe8bdbd51b to your computer and use it in GitHub Desktop.
SearchUIStateHandler uses StateUIValue
@ActivityScope
class SearchUIStateHandler @Inject constructor() {
// ... State UI code
@Composable
fun StateUIValue(uiState: TweetsUIState) {
when (uiState) {
is TweetsUIState.ListResultsUIState -> TweetsList(tweets = uiState.tweets)
// other UI states
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment