# .NET MAUI Templated Rating

The `RadTemplatedRating` component is designed for cases where is easier to provide a template (for example, an image) for the rating items instead of creating custom `RadPathGeometry`.

On top of the [common Rating API](https://www.telerik.com/maui-ui/documentation/controls/rating/configuration), this component adds the following members:

* `ItemTemplate` (`DataTemplate`)—Defines the template used in the rating item.
* `SelectedItemTemplate` (`DataTemplate`)—Specifies the template used in the selected rating item.

> Set both the `ItemTemplate` and `SelectedItemTemplate` templates.

![.NET MAUI Rating Template](https://www.telerik.com/maui-ui/documentation/assets/472db21f17b2607c0ce8e22c8dcd88ae/rating-templates.png)

The following example demonstrates how to define `RadTemplatedRating` in XAML:

```XAML
<telerik:RadTemplatedRating AutomationId="templatedRating" ValueChanged="RadTemplatedRating_ValueChanged">
    <telerik:RadTemplatedRating.ItemTemplate>
        <DataTemplate>
            <Image Source="unread.png" />
        </DataTemplate>
    </telerik:RadTemplatedRating.ItemTemplate>
    <telerik:RadTemplatedRating.SelectedItemTemplate>
        <DataTemplate>
            <Image Source="success.png" />
        </DataTemplate>
    </telerik:RadTemplatedRating.SelectedItemTemplate>
</telerik:RadTemplatedRating>
```

## See Also

* [Configuration of the Rating](https://www.telerik.com/maui-ui/documentation/controls/rating/configuration)
* [Shape Rating](https://www.telerik.com/maui-ui/documentation/controls/rating/rating-shape-rating)
