When I make changes to controllers in MVC I have to re-compile and upload my binaries for the changes to be noticed on my website. This makes sense, but I was wondering is there a way (or some settings) that will allow me to make changes to code/controllers and simply upload the changes without having to compile locally and upload the binaries.
I know with standard asp.net the app will compile automatically with first page load on the server after changes to code-behind files are made. Can something similar be setup for MVC3?
You could use a Web Site project type instead of a Web Application (which is the default for an ASP.NET MVC 3 project). In this case you will have to manually create the project structure (Web Site) and place your controllers inside the App_Code folder which is automatically compiled at runtime. Then you ship your controllers source code to the server.
Definitely not something I would recommend you doing. Simply stick to the standard way of building an ASP.NET MVC 3 application which consists in using a precompiled Web Application project type in which all code behind is compiled in assemblies that you ship in the bin folder.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With