0PricingLogin
Jetpack Compose Academy · Lesson

Passing Arguments Between Screens

Send data along the navigation route.

Screens Need Data

A detail screen needs to know which item to show. Navigation Compose lets you carry that data along the route itself.

Declare a Placeholder

Add a placeholder in curly braces to a route. It marks where a value will slot in when you navigate.

composable("profile/{userId}") { backStackEntry ->
    ProfileScreen()
}

All lessons in this course

  1. NavController & NavHost
  2. Composable Destinations & Routes
  3. Passing Arguments Between Screens
  4. Back Stack & Deep Links
← Back to Jetpack Compose Academy