🌈 Create new beautiful Compose Gradients with our new wesite ->
Function

observe

Register an observer to be notified when a composition is added to or removed from the given Recomposer.

observe

Source set: Common
public fun Recomposer.observe(
    observer: CompositionRegistrationObserver
): CompositionObserverHandle

Register an observer to be notified when a composition is added to or removed from the given Recomposer. When this method is called, the observer will be notified of all currently registered compositions per the documentation in CompositionRegistrationObserver.onCompositionRegistered.

Parameters

observer the observer that will be informed of new compositions registered with this Recomposer.

Return

a handle that allows the observer to be disposed and detached from the Recomposer.