Skip to content
This repository was archived by the owner on Aug 27, 2020. It is now read-only.

DebugConverter

Mark Smith edited this page Aug 29, 2016 · 1 revision

DebugConverter

This value converter can be used to debug bindings by displaying the source and target information. It also implements IMarkupExtension which means it can be created inline with the binding vs. storing as a resource.

Note: You should not leave these in production code, use this value converter for debugging only.

Example

This will output: Convert: Value=blah, TargetType=string, Parameter=, Culture=en-US to the debug console.

<Label xmlns:cvt="clr-namespace:XamarinUniversity.Converters;assembly=XamU.Infrastructure"
   Text="{Binding SomeText, Converter={cvt:DebugConverter}}" ... />