Class

CompositionContext

A CompositionContext is an opaque type that is used to logically "link" two compositions together.

Source set: Common
public abstract class CompositionContext internal constructor()

A CompositionContext is an opaque type that is used to logically "link" two compositions together. The CompositionContext instance represents a reference to the "parent" composition in a specific position of that composition's tree, and the instance can then be given to a new "child" composition. This reference ensures that invalidations and CompositionLocals flow logically through the two compositions as if they were not separate.

The "parent" of a root composition is a Recomposer.

Properties

effectCoroutineContext

Source set: Common
public abstract val effectCoroutineContext: CoroutineContext

The CoroutineContext with which effects for the composition will be executed in.

Functions

scheduleFrameEndCallback

Source set: Common
public abstract fun scheduleFrameEndCallback(action: () -> Unit): CancellationHandle
Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: