> 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/progress-bar.md).

# Progress Bar

Represents a Material UI styled progress indicator for showing ongoing processes or loading states.

### Overview

The `ProgressBar` represents a Material UI-styled progress indicator, designed to provide a visual cue of ongoing activity. It features a rotating arc that animates to indicate progress or loading states.&#x20;

To use the `ProgressBar`, initialize it with optional parameters for line width. By default, the progress bar uses a standard line width of 2 points. You can customize the line width by providing a specific value.

### Initializer

Creates a progress view with the default line width (of 2 points).

```swift
ProgressBar()
```

Creates a progress view with a custom line width.

```swift
ProgressBar(lineWidth: CGFloat)
```

## Parameter

<table><thead><tr><th width="193">Parameter</th><th>Description</th></tr></thead><tbody><tr><td><code>lineWidth</code></td><td>Sets the stroke width of the progress view.</td></tr></tbody></table>

### Example

Displays a ProgressBar with the default line width of  2 points.

```swift
ProgressBar()
```

<figure><img src="https://2931569195-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHpwjDgYAa64eKF8AGmeE%2Fuploads%2FuQI31vtLux0PnWEFO3p7%2FDark%20prg.png?alt=media&amp;token=097862f3-aa50-4ff2-bf8b-c5cab72e3bb5" alt=""><figcaption></figcaption></figure>

Displays a ProgressBar with a custom line width.

```swift
ProgressBar(lineWidth: 5)
```

<figure><picture><source srcset="/files/2C0lgY3DPpQV8H4VxKzJ" media="(prefers-color-scheme: dark)"><img src="https://2931569195-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHpwjDgYAa64eKF8AGmeE%2Fuploads%2FjsG2qbhD2trzFSJRktOw%2Fcustom%20dark.png?alt=media&amp;token=d60104e4-11d1-48ec-b079-4c4699c25558" alt=""></picture><figcaption></figcaption></figure>
