Empty project does not run in NET 9 WebAssembly on browser #17955
Replies: 5 comments
-
Have you tried dotnet workload restore? |
Beta Was this translation helpful? Give feedback.
-
@timunie Just tried that, unfortunately it did not work. I ran it both in project (VS Dev PowerShell) and in Windows cmd prompt. |
Beta Was this translation helpful? Give feedback.
-
Hmm, Browser worked fine for me a week or two ago for me when I tried it from a fresh install with a fresh project. I did create with 11.2.3 (you can type this into the template wizard) and only have 9.0.101 SDK. My
IIRC, I installed via CLI instead of VS: |
Beta Was this translation helpful? Give feedback.
-
Just tried again, specifying Avalonia version 11.2.3 in the wizard. The situation remains the same. |
Beta Was this translation helpful? Give feedback.
-
@fraluderin the wasm tools need to be in the exact correct version matching .NET version. Microsoft is currently breaking it frequently, which can be seen as a good sign imo since it means they are working hard to improve it in general. Also clear the browser cache from time to time. |
Beta Was this translation helpful? Give feedback.
-
Describe the bug
An empty project created with VS 2022 fails to load in browser WebAssembly if targeting NET 9.
To Reproduce
Expected behavior
The app should load as expected; the same project starts to work if target framework is changed to NET 8 on all projects.
Avalonia version
11.2.1
OS
Windows
Additional context
These are the SDKs I have:
NET 8 and NET 9 WebAssembly build tools are installed:
Beta Was this translation helpful? Give feedback.
All reactions