diff --git a/aspnetcore/mvc/views/view-compilation.md b/aspnetcore/mvc/views/view-compilation.md index 92922d06bda0..0ca3c20358b3 100644 --- a/aspnetcore/mvc/views/view-compilation.md +++ b/aspnetcore/mvc/views/view-compilation.md @@ -6,7 +6,7 @@ description: Learn how compilation of Razor files occurs in an ASP.NET Core app. monikerRange: '>= aspnetcore-3.1' ms.author: tdykstra ms.custom: mvc -ms.date: 01/30/2026 +ms.date: 02/06/2026 uid: mvc/views/view-compilation --- # Razor file compilation in ASP.NET Core @@ -16,7 +16,15 @@ uid: mvc/views/view-compilation Razor files with a `.cshtml` extension are compiled at both build and publish time using the [Razor SDK](xref:razor-pages/sdk). Runtime compilation may be optionally enabled by configuring the project. > [!NOTE] -> **Runtime compilation was obsoleted starting in .NET 10. For more information, see [Razor runtime compilation is obsolete](/dotnet/core/compatibility/aspnet-core/10/razor-runtime-compilation-obsolete).** +> Runtime compilation: +> * Was obsoleted starting in .NET 10. +> * Isn't supported for Razor components of Blazor apps. +> * Doesn't support [global using directives](/dotnet/csharp/whats-new/csharp-10#global-using-directives). +> * Doesn't support [implicit using directives](/dotnet/core/tutorials/top-level-templates#implicit-using-directives). +> * Disables [.NET Hot Reload](xref:test/hot-reload). +> * Isn't recommended for production scenarios. +> +> For production scenarios, use the default build-time compilation. For development scenarios, use Hot Reload. For more information, see [Razor runtime compilation is obsolete](/dotnet/core/compatibility/aspnet-core/10/razor-runtime-compilation-obsolete). ## Razor compilation @@ -25,7 +33,7 @@ Build-time and publish-time compilation of Razor files is enabled by default by Updating Razor views and Razor Pages during development while the app is running is also supported using [.NET Hot Reload](xref:test/hot-reload). > [!NOTE] -> **Razor runtime compilation was obsoleted starting in .NET 10. When enabled, runtime compilation disables [.NET Hot Reload](xref:test/hot-reload). We recommend using Hot Reload instead for development scenarios. For more information, see [Razor runtime compilation is obsolete](/dotnet/core/compatibility/aspnet-core/10/razor-runtime-compilation-obsolete).** +> Razor runtime compilation was obsoleted starting in .NET 10. When enabled, runtime compilation disables [.NET Hot Reload](xref:test/hot-reload). We recommend using Hot Reload instead for development scenarios. For more information, see [Razor runtime compilation is obsolete](/dotnet/core/compatibility/aspnet-core/10/razor-runtime-compilation-obsolete). ## Enable runtime compilation for all environments