# StyleReloadTarget

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-hot-reload/struct-stylereloadtarget/

**struct** · [`ferroui-hot-reload`](/docs/0.5.0/api/ferroui-hot-reload/) · v0.5.0

```rust
struct StyleReloadTarget
```

Replaces one style or nested Styles contribution, retaining its container and
application-owned siblings. Native style removal detaches the previous frames;
addition invalidates styling for the owner and its logical descendants.
Register static-resource consumers as dependencies of this document.
Applications caching the replaced style need an explicit refresh adapter.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/styles.rs#L21)

## Members

- [`with_dependencies`](#function-with_dependencies)
- [`contribution`](#function-contribution)
- [`discover`](#function-discover)
- [`is_alive`](#function-is_alive)

<a id="function-with_dependencies"></a>

### with_dependencies

```rust
fn with_dependencies(self: Self, dependencies: impl IntoIterator<Item = String>) -> Self
```

Declares resources/styles outside the document's inline includes, such as
application resources consumed through StaticResource. Their revisions are
prepared and committed in the same transaction as this target.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/styles.rs#L32)

<a id="function-contribution"></a>

### contribution

```rust
fn contribution(container: &Ref<Styles>, index: usize, uri: String, configuration: RuntimeXamlLoaderConfiguration) -> Result<Self, ReloadError>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/styles.rs#L40)

<a id="function-discover"></a>

### discover

```rust
fn discover(container: &Ref<Styles>, configuration: RuntimeXamlLoaderConfiguration) -> Result<Vec<Self>, ReloadError>
```

Discovers direct style includes without evaluating their markup.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/styles.rs#L60)

<a id="function-is_alive"></a>

### is_alive

```rust
fn is_alive(self: &Self) -> bool
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/styles.rs#L78)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- [`ReloadTarget`](/docs/0.5.0/api/ferroui-hot-reload/trait-reloadtarget/)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
