** Either way, it is recommended to keep your UBIKThemes file as lean as possible (read the next point), as well as maintaining a grouping strategy. Use the tags <nowiki><!--#region Example--></nowiki> and <nowiki><!--#endregion--></nowiki> to define groups of content, for example
<nowiki><!--#region Text Styles-->, <!--#region DataTemplates-->, or <!--#region Item Templates--></nowiki>.
[[Category:Pages with broken file links|XAML Best practices]][[Category:XAML|XAML Best practices]]<br><br>
== Performance ==
** Sometimes it’s unavoidable that multiple containers are needed. In Xamarin, applying the [[Xamarin_XAML#Layout_compression_examples|HeadlessLayout]] style can reduce their impact on the visual tree.
** Some ideas for reducing the number of nested controls can be seen [[XAML_Best_practices#Alternatives_to_using_Multiple_Controls|later in this article]].
<br><br>
==== Implicit and Explicit Styling ====
* The localized Style definitions in this StackPanel will be passed down to all controls contained within it, no matter how deep the nesting goes.
* The BasedOn attribute can be used to create a sub-style based on another existing style. However, the TargetType must always match.
<br><br>
==== Content Templating ====