Examine the project file (.csproj) and note that it created a node like this:
<ItemGroup>
<Folder Include="NewFolder1\" />
</ItemGroup>
Now remove the folder in Visual Studio and save the project.
Note that in the project file, there is an empty node, like this:
<ItemGroup/>
Removing the empty node doesn't seem to make any difference, so why does VS leave this behind?
Why do I care? Because commits like this are confusing:
Firstly, an empty ItemGroup
is benign, just as an empty PropertyGroup
is. At worst it's noise in your project file.
Historically, the project file was not really intended for human consumption and only ad-hoc effort was put into keeping it tidy during transformations made by VS.
With the new SDK-style project files, the intent is 100% to have them be human readable and editable. If you see empty groups in VS when using the new project style, it's definitely something the team wants to know about. In such a case, please report a problem and explain in the body that it's for the project system team.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With