Composable Function

rememberCompositionContext

An Effect to construct a CompositionContext at the current point of composition.

rememberCompositionContext

Source set: Common
@Composable
public fun rememberCompositionContext(): CompositionContext

An Effect to construct a CompositionContext at the current point of composition. This can be used to run a separate composition in the context of the current one, preserving CompositionLocals and propagating invalidations. When this call leaves the composition, the context is invalidated.

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: