Reputation: 195
I just installed Visual studio2022 and create a project.NET6 web application with Razor page. But I found that Hot re-load doesn't work even for little changes("TEST" to "TEST1" in screenshot) on Index.cshtml but error popup said "Edits were made which cannot be compiled. So I had to re-build the project to see the changes. But somehow it works when I use start without debugging.
Could anyone please help on this.
Upvotes: 5
Views: 635
Reputation: 162
I don't know that his is the best solution, but you can disable edit and continue so that you don't keep getting prompted. Go to Options->Debugging->General and unselect the 'Enable Edit and Continue and Hot Reload' option. Obviously if you want Edit and continue you may not want this as your solution. VS options
Upvotes: 1