I found several solutions (the 1st option helped me):
1. Disable browser connection
Tools > Options > Project & Solutions > ASP.NET Core
CSS Hot Reload - Disabled
May you need to restart VS after changing that option.
Go to the browser link toolbar and click the arrow pointing down - shown below.
Turn off "Enable browser link" so that it no longer has a check mark
Restart Visual Studio after you have done this.
enter image description here
2. Disable Insights
Tools > Options > Project & Solutions > Web Projects
turn on "Disable local Application Insights for ASP.NET Core web projects"
In file Startup.cs:
public void ConfigureServices(IServiceCollection services){
...
#if !DEBUG
services.AddApplicationInsightsTelemetry();
#endif
...
}
and:
public void Configure(IApplicationBuilder app, IWebHostEnvironment env){
...
#if DEBUG
TelemetryConfiguration.Active.DisableTelemetry = true;
TelemetryDebugWriter.IsTracingDisabled = true;
#endif
...
}
3. Edit file hosts
Add in file hosts:
- 127.0.0.1 dc.services.visualstudio.com
- 127.0.0.1 rt.services.visualstudio.com