Compile aspnet mvc views (*.cshtml)
To make a long story short one can compile the views in asp net mvc.
It takes considerable time though so I only activate it for release compilations.
Update the build file with
1 <MvcBuildViews Condition=" '$(Configuration)' == 'Release' ">true</MvcBuildViews>
Like so:
1
2 <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<MvcBuildViews Condition=" '$(Configuration)' == 'Release' ">true</MvcBuildViews>
I am sorry about all > and < but I don’t have the time right now to make everything look pretty. Just replace > with < and < with > and your good to go.
Or follow the links below with the awesome formatting Stack overflow provides.
Honour those who should. Especially this answer that does the only-release trick.
Tags: aspnetmvc, fail-at-once, razor