Created
August 10, 2022 16:19
-
-
Save krzdabrowski/c9494004a81d9b9358ca742c38e3086e 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
@Composable | |
private fun HandleEvents(events: Flow<RocketsEvent>) { | |
val uriHandler = LocalUriHandler.current | |
events.collectWithLifecycle { | |
when (it) { | |
is OpenWebBrowserWithDetails -> { | |
uriHandler.openUri(it.uri) | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment