Runtime compilation compiles Razor Pages while an ASP.NET Core application is running. Developers can change a page and see the result without stopping and rebuilding the application. section 17.1
Use runtime compilation with these practical boundaries:
- Razor Pages normally compile during the application build and become C# classes behind the scenes. section 17.1
- Enable runtime compilation when iterating on Razor Pages locally without explicitly stopping and rebuilding. section 17.1
- Avoid runtime compilation when deploying to production. section 17.1
Editing a Razor Page while the app runs
Start an ASP.NET Core Razor Pages application, modify its Razor template, and reload the page. With runtime compilation enabled, the changed page can be rendered without an explicit stop-and-rebuild cycle. section 17.1
