Scaffold
The Scaffold is the basic layout structure used on a screen.
Scaffold(
topBar = { /* */ },
bottomBar = { /* */ },
snackbarHost = { /* */ },
floatingActionButton = { /* */ }
) {
/* Content */
}
On its own, the Scaffold doesnโt show anything, but provides a frame for other components to hang off of.
A screen should have its content wrapped in a Scaffold. Your top and bottom App Bars can be put in this structure. If you have a FloatingActionButton
without a bottom app bar, you can put it into the Scaffold structure too.
All other components should be put within the body of the Scaffold.
Scaffold {
// Content
Column { /* */ }
}