How to compile cshtml before runtime

asp.net-mvc, jquery-mobile, razor

Solution

Set `<MvcBuildViews>true</MvcBuildViews>` in the `<PropertyGroup>` element of your .csproj file.

Problem

I believe I read somewhere there is a setting in one of the project files that will allow you to compile the `.cshtml` files when building your Visual Studio project. Just getting started with `MVC/Razor/Query` Mobile, and am getting annoyed with the "Error loading page" when I have an error in a code block inside a `.cshtml` file

Original source

Related problems