If you precompile a web site and keep it updatable, the ASP.NET parser can see from the Page directive that there is no codefile or codebehind and where to find the base class (inherits attribute).
<%@ page language="C#" autoeventwireup="true" inherits="_Default, Precompiled"
theme="Default" validaterequest="false" %>
If the site is precompiled and not updatable, the .compiled files in the bin folder should give the ASP.NET runtime all the necesary information on how to instantiate the page classes.
So why is the precompiledApp.config needed?
Thanks!
If you choose the option to not make your pages updateable (i.e. uncheck the first checkbox in the advanced settings dialog), it will also precompile your views (ASPX and Razor) instead of compiling those dynamically at runtime as well.
In order for the ASP.NET engine to service a request for this page, the page's code portion (the WebPage. aspx. cs file) must first be compiled. This compilation can happen explicitly or automatically.
Precompiling for Deployment and Update aspx files into single files that use the compiled code-behind model and copies them to the layout. This option enables you to make limited changes to the ASP.NET Web pages in the site after you compile them.
It's used to indicate whether or not the ASPX/ASCX pages in your site are updateable or not. You can precompile and have the code behind compiled, but leave these pages updateable so you can make minor GUI-related tweaks should you wish.
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