---
title: "rememberBackdropScaffoldState"
description: "Create and [remember] a [BackdropScaffoldState]."
type: "composable"
---

<div class='type'>Composable Function</div>


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

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


```kotlin
@Composable
fun rememberBackdropScaffoldState(
    initialValue: BackdropValue,
    animationSpec: AnimationSpec<Float> = BackdropScaffoldDefaults.AnimationSpec,
    confirmStateChange: (BackdropValue) -> Boolean = { true },
    snackbarHostState: SnackbarHostState = remember { SnackbarHostState() },
): BackdropScaffoldState
```


Create and `remember` a `BackdropScaffoldState`.

#### Parameters

| | |
| --- | --- |
| initialValue | The initial value of the state. |
| animationSpec | The default animation that will be used to animate to a new state. |
| confirmStateChange | Optional callback invoked to confirm or veto a pending state change. |
| snackbarHostState | The `SnackbarHostState` used to show snackbars inside the scaffold. |





