> For the complete documentation index, see [llms.txt](https://swift-packages.gitbook.io/materialuikit/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://swift-packages.gitbook.io/materialuikit/components/container.md).

# Container

### Overview

The `Container` provides an empty view container with default MaterialUIKit styling. It wraps any provided content within a styled background with consistent padding and spacing as defined by the configuration settings. For more information about configuration settings refer to[MUIKitConfiguration](/materialuikit/configuration-and-color-schemes/muikitconfiguration.md)

To use the `Container`, initialize it with a closure that returns the content to be displayed within the container.&#x20;

> Do not use `Container` with `NavigationContainer`, as the latter already includes a default configuration for styling and layout.

### Initializer

Creates an empty container view.

```swift
Container(@ViewBuilder content: () -> Content)
```

### Parameter

<table><thead><tr><th width="156">Parameter</th><th>Description</th></tr></thead><tbody><tr><td><code>content</code></td><td>The content to be wrapped in the container view.</td></tr></tbody></table>

### Example

```swift
Container {
    Text("Hello, World!")
        .font(MaterialUIKit.configuration.h1)
        .foregroundColor(.materialUIPrimaryTitle)
}
```
