<div class='type'>Interface</div>


<a id='references'></a>

<div class='sourceset sourceset-common'>Common</div>



```kotlin
public interface HostDefaultProvider
```


An interface that allows the hosting environment (e.g., Android, Desktop, or iOS) to provide
default values for `CompositionLocal` using `compositionLocalWithHostDefaultOf`.

This acts as a decoupling layer, allowing platform-agnostic libraries to request
platform-specific components ((like `LifecycleOwner` or `ViewModelStoreOwner`) without depending
on platform-specific APIs or artifacts.


## Functions



<h2 id="gethostdefault-key">getHostDefault</h2>

```kotlin
public fun <T> getHostDefault(key: HostDefaultKey<T>): T
```


Retrieves a value associated with `key` from the host environment.