I get this error in vs 2022 and a blazor wasm standalone project. I can resolve it by this solution :