Back to Blog
27 Apr 2020
Updated 19 Aug 2026
1 min read
1263 Views
Xamarin Forms: Compiled Bindings
Using Compiled Bindings improves the speed of Data Binding on Xamarin Forms and better it will detect Data Binding Errors on Compile Time.
The following code example demonstrates enabling XAML compilation at the assembly level:
using Xamarin.Forms.Xaml;
…
[assembly: XamlCompilation (XamlCompilationOptions.Compile)]
namespace PhotoApp
{
…
}The following code example demonstrates enabling XAML compilation at the class level:
using Xamarin.Forms.Xaml;
...
[XamlCompilation (XamlCompilationOptions.Compile)]
public class HomePage : ContentPage
{
...
}Comments
Have a question, or found an issue with the code? Drop a comment below — I read and reply to every one.
Loading comments…