我有一个带有第 5 版程序集的 Blazor WASM 项目,并尝试根据本文激活调试:https ://docs.microsoft.com/en-us/aspnet/core/blazor/debug?view=aspnetcore-3.1
为此,我确保更新了所有程序集引用并调整了启动设置。后者现在看起来像这样:
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:62310",
"sslPort": 44325
}
},
"profiles": {
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"ApplySupportTool.Client": {
"commandName": "Project",
"launchBrowser": true,
"inspectUri": "{wsProtocol}://{url.hostname}:{url.port}/_framework/debug/ws-proxy?browser={browserInspectUri}",
"applicationUrl": "https://localhost:5001;http://localhost:5000",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}
Run Code Online (Sandbox Code Playgroud)
这些也是我在 WASM 项目中的参考资料:
<PackageReference Include="System.Net.Http.Json" Version="3.2.0-preview5.20210.3" />
<PackageReference Include="Microsoft.AspNetCore.Components.DataAnnotations.Validation" Version="3.2.0-preview2.20160.5" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="3.2.0-preview5.20216.8" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Build" Version="3.2.0-preview5.20216.8" PrivateAssets="all" />
<PackageReference …Run Code Online (Sandbox Code Playgroud) 我正在尝试调试我的 Visual Studio C# Blazor 项目,但是每当我尝试设置断点时,我都会收到错误“当前不会命中断点。未绑定断点。” 或“尚未加载任何符号。” 我一直能够调试直到最新的视觉版本。我已经尝试过以下方法:
如果有人能给我任何关于如何解决这个问题的建议,我将不胜感激。