>
> The old .NET Framework project system ignores conditions on
> Items/ItemGroups (Choose is a workaround).
>
> The new SDK-based project system doesn’t suffer from this problem, and
> honors conditions on everything.
>
Chaps, in VS2019 Configuration Manager dialog this morning I removed all
custom configurations and added them back, remembering to check *Create new
project configuration*. In the project I added elements like these:
<ItemGroup Condition="'$(Configuration)'=='ReleaseLocal'">
<Content Remove="wwwroot\site-debug.js" />
* ---- etc remove content files NOT to be released in this config ---*
</ItemGroup>
So I Remove the items I *don't* want for each config. This works in build
and publish. The inverse doesn't work, if I Remove all items first then
Include the ones I want then it works in build, but none are published.
I think my publish failure yesterday was incorrect config dialog settings.
After adding it all back, it all works (subject to the caveat above).
Thanks, *Greg K*
P.S. <Choose> works as well, but I don't need it in the Blazor net5.0 sdk
project.