0

How do I precompile an ASP.Net MVC4 website in Visual Studio 2010 at the time of Publishing?

I didn't find any option in Visual Studio project / solution settings. I checked the Package/Publish Setting by right clicking on the project but didn't find any relevant settings.

I know there exists command line option (aspnet_compile.exe) but I wish to achieve this using Visual Studio 2010.

Kabeer
  • 4,138
  • 7
  • 40
  • 62
  • possible duplicate of [Precompile a asp.net4 mvc3 website using visual studio 2010](http://stackoverflow.com/questions/7166820/precompile-a-asp-net4-mvc3-website-using-visual-studio-2010) – Rowan Freeman Aug 27 '14 at 04:25

1 Answers1

0

well.project is already compiled when you publish it(except views).if you want to compile views,then edit your projet file and add

<MvcBuildViews>true</MvcBuildViews>

ps: you have to unload project before you can edit project file

AfterGlow
  • 227
  • 3
  • 17