Lately I’ve experienced a very slow editing on Razor pages in Visual Studio 2013. I had a set of extensions installed, but nothing special: Resharper 8.1, Web Essentials and VSCommands. When I was editing Razor .cshtml file, every keystroke was painfully slow, especially when I was trying to edit C# code there: we have a lot of helpers and html generation tools, our view are almost html-free, only control builders.

Long story short, by disabling extension one by one, I’ve narrowed down the performance issue to Web Essentials setting that tries to auto-format HTML.

To fix that in Visual Studio 2013 go to Tools -> Options; select Web Essentials section and HTML sub-section; and disable Auto-format HTML on Enter: