AvaloniaVS icon indicating copy to clipboard operation
AvaloniaVS copied to clipboard

XAML Styler not working with new Avalonia for Visual Studio extension

Open mgarstenauer opened this issue 6 months ago • 5 comments

Describe the bug

I am using XAML Styler for Visual Studio 2022 v3.2501.8 (https://github.com/Xavalon/XamlStyler). After upgrading to the new Avalonia for Visual Studio v11.10.4.0, XAML Styler stopped working for *.axaml files. I can select Format XAML in the context menu, but the XAML file does not change.

XAML Styler still works for Avalonia XAML files with the .xaml extension.

To Reproduce

  1. Install the Avalonia for Visual Studio extension in Visual Studio 2022.
  2. Install the XAML Styler extension in Visual Studio 2022.
  3. Open a .axaml file from any Avalonia project.
  4. Select Format XAML from the document context menu.

Expected result: The XAML document should be reformatted based on the XAML styler settings.

AvaloniaVS plugin version

11.10.4.0

Avalonia version

11.3.6

Visual Studio version

17.14.16

Relevant log output

-

Additional context

XAML Styler worked fine with the previous Avalonia Visual Studio extension. Therefore, I hope that this can be fixed in the new extension.

mgarstenauer avatar Oct 14 '25 13:10 mgarstenauer

Same here. XAML Styler works, if I activate the Avalonia extension it stops working.

dpieve avatar Oct 14 '25 15:10 dpieve

XAML Styler still works for Avalonia XAML files

if I activate the Avalonia extension it stops working

Same here. Has anyone been able to solve the problem?

vldkamsin avatar Oct 17 '25 14:10 vldkamsin

The issue is with how they determine which documents can be formatted.

Please upvote the issue on their repository and encourage them to accept this PR which fixes the issue for them.

mrlacey avatar Oct 17 '25 15:10 mrlacey

XAMLStyler have merged the fix, hopefully they'll release an updated version soon.

mrlacey avatar Oct 20 '25 11:10 mrlacey

Looking forward to a new version with this fix.

Jack251970 avatar Nov 02 '25 12:11 Jack251970