Description
When running winapp init, the generated asset files (StoreLogo, AppList, MedTile, WideTile, etc.) are placed in the Assets\ folder but are not added as <Content> items in the .csproj. This causes the MSIX tooling to exclude them from the generated .build.appxrecipe file, meaning the package layout is missing the visual assets referenced in Package.appxmanifest.
This is not limited to a specific project type (e.g. WPF) — any project that doesn't automatically treat image files as Content items will have this problem. The <Content> items should be added to the csproj for all project types during winapp init.
Steps to Reproduce
- Create a project and run
winapp init
- Run
dotnet build
- Inspect the generated
.build.appxrecipe in the output folder — no Assets\* entries are present
Expected Behavior
The assets should be added as <Content> items in the csproj during winapp init, e.g.:
<ItemGroup>
<Content Include="Assets\StoreLogo.png" />
<Content Include="Assets\MedTile.png" />
<Content Include="Assets\MedTile.scale-200.png" />
<Content Include="Assets\AppList.png" />
<Content Include="Assets\AppList.scale-200.png" />
<Content Include="Assets\AppList.targetsize-24_altform-unplated.png" />
<Content Include="Assets\WideTile.png" />
<Content Include="Assets\WideTile.scale-200.png" />
</ItemGroup>
Actual Behavior
No <Content> items are added for the generated assets. Project SDKs that don't auto-include image files as Content (such as WPF's UseWPF) will result in the MSIX build tooling never picking up the assets.
Additional Context
WinUI projects created via the Visual Studio template already include explicit <Content> items for assets, which is why they work correctly. The winapp init flow should do the same for all project types.
Description
When running
winapp init, the generated asset files (StoreLogo, AppList, MedTile, WideTile, etc.) are placed in theAssets\folder but are not added as<Content>items in the.csproj. This causes the MSIX tooling to exclude them from the generated.build.appxrecipefile, meaning the package layout is missing the visual assets referenced inPackage.appxmanifest.This is not limited to a specific project type (e.g. WPF) — any project that doesn't automatically treat image files as
Contentitems will have this problem. The<Content>items should be added to the csproj for all project types duringwinapp init.Steps to Reproduce
winapp initdotnet build.build.appxrecipein the output folder — noAssets\*entries are presentExpected Behavior
The assets should be added as
<Content>items in the csproj duringwinapp init, e.g.:Actual Behavior
No
<Content>items are added for the generated assets. Project SDKs that don't auto-include image files asContent(such as WPF'sUseWPF) will result in the MSIX build tooling never picking up the assets.Additional Context
WinUI projects created via the Visual Studio template already include explicit
<Content>items for assets, which is why they work correctly. Thewinapp initflow should do the same for all project types.