# xaml

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-view/xaml/function-xaml/

**function** · [`ferroui-view`](/docs/0.5.0/api/ferroui-view/) · v0.5.0

```rust
fn xaml(text: &str) -> crate::element::Element
```

An element of XAML text: the control it loads (see [`load_xaml`](/docs/0.5.0/api/ferroui-view/xaml/function-load_xaml/)).
In a component that runs again, use [`use_xaml`](/docs/0.5.0/api/ferroui-view/xaml/function-use_xaml/), which loads once.
## Panics
Panics with the message of the loader when the XAML does not load.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.View/xaml.rs#L56)

## Availability

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