composable( route = Screen.RestaurantMenu....
# compose
n
composable( route = Screen.RestaurantMenu.route, // Uses "restaurantMenu/{restaurantId}" arguments = listOf(navArgument("restaurantId") { type = NavType.StringType }) // Define argument type ) { backStackEntry -> // You can retrieve the argument here too if needed directly in Composable, // but ViewModel is preferred for business logic. // val restaurantIdFromArgs = backStackEntry.arguments?.getString("restaurantId") // Pass restaurant name if you have it from a previous screen or fetch it // For simplicity, let's assume you might pass it or fetch it in ViewModel RestaurantMenuScreen( // viewModel is handled by Hilt restaurantName = backStackEntry.arguments?.getString("restaurantName") // Optional: if you also pass name ) } hey there, could you help what do mean of that code .
🧵 3