Skip to content

Instantly share code, notes, and snippets.

@dilrajsingh1997
Created November 20, 2021 13:12
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 dilrajsingh1997/ec055fe7d5fddef833294c52e5cfac3c to your computer and use it in GitHub Desktop.
Save dilrajsingh1997/ec055fe7d5fddef833294c52e5cfac3c to your computer and use it in GitHub Desktop.
composable(
route = UserPageDestination.route,
arguments = UserPageDestination.argumentList
) { backStackEntry ->
val (userId, isLoggedIn) = UserPageDestination.parseArguments(backStackEntry)
Box(modifier = Modifier.fillMaxSize()) {
Column(
modifier = Modifier.align(Alignment.Center),
horizontalAlignment = Alignment.CenterHorizontally
) {
Text(text = "This is user page with userId: $userId", textAlign = TextAlign.Center)
Spacer(modifier = Modifier.height(20.dp))
Text(text = "Is user logged in $isLoggedIn", textAlign = TextAlign.Center)
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment