Last active
June 27, 2023 13:21
-
-
Save tdcolvin/3d55485bac3fc52c4d20b966ff8f5e8e 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
data class AddEditPlanetUiState( | |
val planetName: String = "", | |
val planetDistanceLy: Float = 1.0F, | |
val planetDiscovered: Date = Date(), | |
val isLoading: Boolean = false, | |
val isPlanetSaved: Boolean = false | |
) | |
@HiltViewModel | |
class AddEditPlanetViewModel @Inject constructor(): ViewModel() { | |
private val _uiState = MutableStateFlow(AddEditPlanetUiState()) | |
val uiState: StateFlow<AddEditPlanetUiState> = _uiState.asStateFlow() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment