Package-level declarations

Properties

Link copied to clipboard

The nearest enclosing PortholeScreen name, so leaf nodes know where they live.

Link copied to clipboard

Semantics key carrying the porthole's node id.

Functions

Link copied to clipboard
fun <T> StateFlow<T>.collectAsNamedState(name: String): State<T>

Like collectAsState, but tells the porthole what the resulting State is called.

Link copied to clipboard
fun PortholeBackStack(backStack: List<Any>, label: (Any) -> String = ::defaultRouteLabel)

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

Link copied to clipboard

Counts recompositions of the composable that applies it, and stamps the node id into semantics so the two trees line up.

Link copied to clipboard

Stable identity for a call site.

Link copied to clipboard
fun PortholeRoot(name: String = "root", content: @Composable () -> Unit)

Wrap your app's root composable once. Gives the semantics collector a View to walk and establishes the timeline's root scope.

Link copied to clipboard
fun PortholeScreen(name: String, content: @Composable () -> Unit)

Marks a screen. Recompositions of this scope are counted and attributed, and every portholeNode underneath inherits the name.

Link copied to clipboard

remember { mutableStateOf(...) } with a name attached.