Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Cannot exclude bloat from Microsoft.Web.WebView2 package #4860

Open
znakeeye opened this issue Oct 11, 2024 · 1 comment
Open

[Bug]: Cannot exclude bloat from Microsoft.Web.WebView2 package #4860

znakeeye opened this issue Oct 11, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@znakeeye
Copy link

What happened?

Referencing Microsoft.Web.WebView2 produces significant bloat in the output folder. The same goes for deployed app. All in all, 1 MB which can be throw away. But how?

Importance

Moderate. My app's user experience is affected, but still usable.

Runtime Channel

Stable release (WebView2 Runtime)

Runtime Version

1.0.2792.45

SDK Version

No response

Framework

WPF

Operating System

Windows 10

OS Version

No response

Repro steps

  1. Create a WPF project targeting .NET 8.
  2. Add a reference to WebView2 as shown below.
  3. Optionally add an x64 configuration and select it.
<ItemGroup>
  <PackageReference Include="Microsoft.Web.WebView2" Version="1.0.2792.45" />
</ItemGroup>

Now look in the build folder. Why do we see all this bloat? Targeting WPF and x64 we certainly don't need all this:

  • Microsoft.Web.WebView2.Core.xml
  • Microsoft.Web.WebView2.WinForms.dll
  • Microsoft.Web.WebView2.WinForms.xml
  • Microsoft.Web.WebView2.Wpf.xml
  • runtimes/win-arm64/native/WebView2Loader.dll
  • OK: runtimes/win-x64/native/WebView2Loader.dll
  • runtimes/win-x86/native/WebView2Loader.dll

Repros in Edge Browser

No, issue does not reproduce in the corresponding Edge version

Regression

No, this never worked

Last working version (if regression)

No response

@znakeeye znakeeye added the bug Something isn't working label Oct 11, 2024
@Danielx64
Copy link

From my history, that always been the case with having those extra files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants