PortholeBackStack

fun PortholeBackStack(backStack: List<Any>, label: (Any) -> String = ::defaultRouteLabel)(source)

Reports a back stack the app owns, such as Navigation 3's.

val backStack = rememberNavBackStack(HomeKey)
PortholeBackStack(backStack)
NavDisplay(backStack = backStack, ...)

Navigation 3 has no NavController, so there is nothing to auto-detect: the back stack is a snapshot list in app code and has to be handed over. One call beside the NavDisplay does it, and the entries land in the same navigation lane a NavController's would.

label turns an entry into the route shown on the timeline. The default is the class's simple name, which is what a Nav3 key usually is.