Skip to content

Instantly share code, notes, and snippets.

@skydoves
Created March 6, 2024 04:43
Show Gist options
  • Save skydoves/876c368ea7c813d8d0993fc0521fd7c5 to your computer and use it in GitHub Desktop.
Save skydoves/876c368ea7c813d8d0993fc0521fd7c5 to your computer and use it in GitHub Desktop.
stable_ui_state
@Stable
interface UiState<T : Result<T>> {
val value: T?
val exception: Throwable?
val hasSuccess: Boolean
get() = exception == null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment