-
-
Notifications
You must be signed in to change notification settings - Fork 143
Closed
Description
Describe the bug
The formatting fails with an error messagebox with the following content:
Error in StylerPackage:
'<', hexadecimal value 0x3C, is an invalid attribute character.
Line 9, position 5.
This occurs when a comment that contains the string "xmlns:" is located above an XAML element anywhere.
The XAML element needs at least one set property (as in x:Name="Button" or Foreground="Black")
To Reproduce
Steps to reproduce the behavior:
- Create a new XAML file (ResourceDictionary in the example)
- Add some XAML element and a comment containing 'xmlns:' that is located above the element
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<!-- Comment that contains 'xmlns:' -->
<Style x:Key="SomeStyle" />
</ResourceDictionary>Version Info (please complete the following information):
- OS: Windows 10 Pro (21H2)
- Visual Studio: VS2022 (17.5.5)
- XAML Styler: Extension (3.2208.1)
