Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation
10.0.0-preview.3.25172.1
Prefix Reserved
dotnet add package Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation --version 10.0.0-preview.3.25172.1
NuGet\Install-Package Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation -Version 10.0.0-preview.3.25172.1
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="10.0.0-preview.3.25172.1" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="10.0.0-preview.3.25172.1" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" />
paket add Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation --version 10.0.0-preview.3.25172.1
#r "nuget: Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation, 10.0.0-preview.3.25172.1"
#addin nuget:?package=Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation&version=10.0.0-preview.3.25172.1&prerelease
#tool nuget:?package=Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation&version=10.0.0-preview.3.25172.1&prerelease
About
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation is a NuGet package designed to provide runtime compilation support for Razor views in ASP.NET Core MVC applications. This package enables developers to modify and update Razor views without needing to restart the application, facilitating a more dynamic development experience.
Key Features
- Runtime compilation of Razor views in ASP.NET Core MVC applications.
- Allows developers to modify Razor views without restarting the application.
- Supports faster iteration and development cycles.
- Compatible with ASP.NET Core 3.0 and newer.
Limitations
- Isn't supported for Razor components of Blazor apps.
- Doesn't support global using directives.
- Doesn't support implicit using directives.
- Disables .NET Hot Reload.
- Is recommended for development, not for production.
How to Use
To start using Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation in your ASP.NET Core MVC application, follow these steps:
Installation
Install the package via NuGet Package Manager or .NET CLI:
dotnet add package Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation
Configuration
In your Startup.cs file, configure runtime compilation for Razor views:
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.DependencyInjection;
public void ConfigureServices(IServiceCollection services)
{
services.AddControllersWithViews()
.AddRazorRuntimeCompilation();
}
Usage
Now, you can modify Razor views in your application, and the changes will be picked up dynamically without requiring a restart:
@{
ViewData["Title"] = "Home Page";
}
<h2>@ViewData["Title"]</h2>
<p>Welcome to the ASP.NET Core MVC application!</p>
For more information on using runtime compilation for Razor views in ASP.NET Core MVC, refer to the official documentation.
Main Types
The main types provided by this library are:
RazorRuntimeCompilationMvcBuilderExtensions
: Extension methods for configuring runtime compilation for Razor views.RazorRuntimeCompilationMvcOptions
: Options for configuring runtime compilation settings.
Additional Documentation
Feedback & Contributing
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation is released as open-source under the MIT license. Bug reports and contributions are welcome at the GitHub repository.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net10.0 is compatible. |
-
net10.0
- Microsoft.AspNetCore.Mvc.Razor.Extensions (>= 6.0.0)
- Microsoft.CodeAnalysis.Razor (>= 6.0.0)
- Microsoft.Extensions.DependencyModel (>= 10.0.0-preview.3.25171.5)
NuGet packages (460)
Showing the top 5 NuGet packages that depend on Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation:
Package | Downloads |
---|---|
Umbraco.Cms.Web.Common
Contains the web assembly needed to run Umbraco CMS. |
|
Volo.Abp.AspNetCore.Mvc
Package Description |
|
Abp.AspNetCore
Abp.AspNetCore |
|
Wkhtmltopdf.NetCore
This project implements the library wkhtmltopdf for asp net core and a view engine, working in windows, macos, linux and docker. For more information about how to use it, go to https://github.com/fpanaccia/Wkhtmltopdf.NetCore.Example |
|
OrchardCore.Mvc.Core
Orchard Core Framework is an application framework for building modular, multi-tenant applications on ASP.NET Core. Core Implementation for MVC application. |
GitHub repositories (126)
Showing the top 20 popular GitHub repositories that depend on Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation:
Repository | Stars |
---|---|
abpframework/abp
Open-source web application framework for ASP.NET Core! Offers an opinionated architecture to build enterprise software solutions with best practices on top of the .NET. Provides the fundamental infrastructure, cross-cutting-concern implementations, startup templates, application modules, UI themes, tooling and documentation.
|
|
dotnet/AspNetCore.Docs
Documentation for ASP.NET Core
|
|
aspnetboilerplate/aspnetboilerplate
ASP.NET Boilerplate - Web Application Framework
|
|
nopSolutions/nopCommerce
ASP.NET Core eCommerce software. nopCommerce is a free and open-source shopping cart.
|
|
OrchardCMS/OrchardCore
Orchard Core is an open-source modular and multi-tenant application framework built with ASP.NET Core, and a content management system (CMS) built on top of that framework.
|
|
btcpayserver/btcpayserver
Accept Bitcoin payments. Free, open-source & self-hosted, Bitcoin payment processor.
|
|
EduardoPires/EquinoxProject
Web Application ASP.NET 9 using Clean Architecture, DDD, CQRS, Event Sourcing and a lot of good practices
|
|
ServiceStack/ServiceStack
Thoughtfully architected, obscenely fast, thoroughly enjoyable web services for all
|
|
umbraco/Umbraco-CMS
Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
|
|
dotnetcore/Util
Util是一个.Net平台下的应用框架,旨在提升中小团队的开发能力,由工具类、分层架构基类、Ui组件,配套代码生成模板,权限等组成。
|
|
dotnetcore/WTM
Use WTM to write .netcore app fast !!!
|
|
jamesmh/coravel
Near-zero config .NET library that makes advanced application features like Task Scheduling, Caching, Queuing, Event Broadcasting, and more a breeze!
|
|
dotnetcore/DotnetSpider
DotnetSpider, a .NET standard web crawling library. It is lightweight, efficient and fast high-level web crawling & scraping framework
|
|
skoruba/IdentityServer4.Admin
The administration for the IdentityServer4 and Asp.Net Core Identity
|
|
SciSharp/LLamaSharp
A C#/.NET library to run LLM (🦙LLaMA/LLaVA) on your local device efficiently.
|
|
dotnet/aspnet-api-versioning
Provides a set of libraries which add service API versioning to ASP.NET Web API, OData with ASP.NET Web API, and ASP.NET Core.
|
|
loic-sharma/BaGet
A lightweight NuGet and symbol server
|
|
liukuo362573/YiShaAdmin
基于 .NET Core MVC 的权限管理系统,代码易读易懂、界面简洁美观
|
|
Squidex/squidex
Headless CMS and Content Managment Hub
|
|
PiranhaCMS/piranha.core
Piranha CMS is the friendly editor-focused CMS for .NET that can be used both as an integrated CMS or as a headless API.
|
Version | Downloads | Last updated | |
---|---|---|---|
10.0.0-preview.3.25172.1 | 462 | 4/10/2025 | |
10.0.0-preview.2.25164.1 | 661 | 3/18/2025 | |
10.0.0-preview.1.25120.3 | 816 | 2/25/2025 | |
9.0.4 | 32,741 | 4/8/2025 | |
9.0.3 | 111,675 | 3/11/2025 | |
9.0.2 | 162,223 | 2/11/2025 | |
9.0.1 | 151,480 | 1/14/2025 | |
9.0.0 | 625,197 | 11/12/2024 | |
9.0.0-rc.2.24474.3 | 11,697 | 10/8/2024 | |
9.0.0-rc.1.24452.1 | 6,522 | 9/10/2024 | |
9.0.0-preview.7.24406.2 | 1,426 | 8/13/2024 | |
9.0.0-preview.6.24328.4 | 9,068 | 7/9/2024 | |
9.0.0-preview.5.24306.11 | 1,165 | 6/11/2024 | |
9.0.0-preview.4.24267.6 | 783 | 5/21/2024 | |
9.0.0-preview.3.24172.13 | 1,491 | 4/11/2024 | |
9.0.0-preview.2.24128.4 | 1,243 | 3/12/2024 | |
9.0.0-preview.1.24081.5 | 3,235 | 2/13/2024 | |
8.0.15 | 25,181 | 4/8/2025 | |
8.0.14 | 138,151 | 3/11/2025 | |
8.0.13 | 168,718 | 2/11/2025 | |
8.0.12 | 255,505 | 1/14/2025 | |
8.0.11 | 946,848 | 11/12/2024 | |
8.0.10 | 1,067,406 | 10/8/2024 | |
8.0.8 | 1,599,542 | 8/13/2024 | |
8.0.7 | 756,380 | 7/9/2024 | |
8.0.6 | 1,156,059 | 5/28/2024 | |
8.0.5 | 402,543 | 5/14/2024 | |
8.0.4 | 1,417,667 | 4/9/2024 | |
8.0.3 | 738,664 | 3/12/2024 | |
8.0.2 | 656,883 | 2/13/2024 | |
8.0.1 | 1,686,102 | 1/9/2024 | |
8.0.0 | 2,838,612 | 11/14/2023 | |
8.0.0-rc.2.23480.2 | 23,344 | 10/10/2023 | |
8.0.0-rc.1.23421.29 | 8,703 | 9/12/2023 | |
8.0.0-preview.7.23375.9 | 3,466 | 8/8/2023 | |
8.0.0-preview.6.23329.11 | 4,654 | 7/11/2023 | |
8.0.0-preview.5.23302.2 | 3,192 | 6/13/2023 | |
8.0.0-preview.4.23260.4 | 234,742 | 5/16/2023 | |
8.0.0-preview.3.23177.8 | 2,966 | 4/11/2023 | |
8.0.0-preview.2.23153.2 | 3,975 | 3/14/2023 | |
8.0.0-preview.1.23112.2 | 2,986 | 2/21/2023 | |
7.0.20 | 90,290 | 5/28/2024 | |
7.0.19 | 18,428 | 5/14/2024 | |
7.0.18 | 42,841 | 4/9/2024 | |
7.0.17 | 77,179 | 3/12/2024 | |
7.0.16 | 65,845 | 2/13/2024 | |
7.0.15 | 124,195 | 1/9/2024 | |
7.0.14 | 283,263 | 11/14/2023 | |
7.0.13 | 280,620 | 10/24/2023 | |
7.0.12 | 190,831 | 10/10/2023 | |
7.0.11 | 358,692 | 9/12/2023 | |
7.0.10 | 684,644 | 8/8/2023 | |
7.0.9 | 446,014 | 7/11/2023 | |
7.0.8 | 257,031 | 6/22/2023 | |
7.0.7 | 644,046 | 6/13/2023 | |
7.0.5 | 880,857 | 4/11/2023 | |
7.0.4 | 471,576 | 3/14/2023 | |
7.0.3 | 441,795 | 2/14/2023 | |
7.0.2 | 768,376 | 1/10/2023 | |
7.0.1 | 636,450 | 12/13/2022 | |
7.0.0 | 2,005,789 | 11/7/2022 | |
7.0.0-rc.2.22476.2 | 16,328 | 10/11/2022 | |
7.0.0-rc.1.22427.2 | 3,770 | 9/14/2022 | |
7.0.0-preview.7.22376.6 | 4,177 | 8/9/2022 | |
7.0.0-preview.6.22330.3 | 1,706 | 7/12/2022 | |
7.0.0-preview.5.22303.8 | 1,514 | 6/14/2022 | |
7.0.0-preview.4.22251.1 | 2,022 | 5/10/2022 | |
7.0.0-preview.3.22178.4 | 1,505 | 4/13/2022 | |
7.0.0-preview.2.22153.2 | 2,063 | 3/14/2022 | |
7.0.0-preview.1.22109.13 | 1,758 | 2/17/2022 | |
6.0.36 | 71,882 | 11/12/2024 | |
6.0.35 | 44,099 | 10/8/2024 | |
6.0.33 | 90,627 | 8/13/2024 | |
6.0.32 | 139,455 | 7/9/2024 | |
6.0.31 | 90,735 | 5/28/2024 | |
6.0.30 | 46,827 | 5/14/2024 | |
6.0.29 | 116,360 | 4/9/2024 | |
6.0.28 | 92,108 | 3/12/2024 | |
6.0.27 | 1,879,706 | 2/13/2024 | |
6.0.26 | 272,847 | 1/9/2024 | |
6.0.25 | 676,056 | 11/14/2023 | |
6.0.24 | 432,333 | 10/24/2023 | |
6.0.23 | 150,824 | 10/10/2023 | |
6.0.22 | 267,460 | 9/12/2023 | |
6.0.21 | 385,214 | 8/8/2023 | |
6.0.20 | 262,219 | 7/11/2023 | |
6.0.19 | 185,418 | 6/22/2023 | |
6.0.18 | 95,006 | 6/13/2023 | |
6.0.16 | 852,438 | 4/11/2023 | |
6.0.15 | 629,961 | 3/14/2023 | |
6.0.14 | 394,521 | 2/14/2023 | |
6.0.13 | 588,952 | 1/10/2023 | |
6.0.12 | 1,536,729 | 12/13/2022 | |
6.0.11 | 905,910 | 11/7/2022 | |
6.0.10 | 1,581,407 | 10/11/2022 | |
6.0.9 | 1,017,597 | 9/13/2022 | |
6.0.8 | 1,324,612 | 8/9/2022 | |
6.0.7 | 1,775,408 | 7/12/2022 | |
6.0.6 | 992,348 | 6/14/2022 | |
6.0.5 | 5,297,322 | 5/10/2022 | |
6.0.4 | 1,265,626 | 4/11/2022 | |
6.0.3 | 1,220,798 | 3/8/2022 | |
6.0.2 | 843,830 | 2/8/2022 | |
6.0.1 | 2,170,240 | 12/14/2021 | |
6.0.0 | 3,056,052 | 11/8/2021 | |
6.0.0-rc.2.21480.10 | 18,178 | 10/12/2021 | |
6.0.0-rc.1.21452.15 | 20,066 | 9/14/2021 | |
6.0.0-preview.7.21378.6 | 13,315 | 8/10/2021 | |
6.0.0-preview.6.21355.2 | 7,279 | 7/14/2021 | |
6.0.0-preview.5.21301.17 | 6,701 | 6/15/2021 | |
6.0.0-preview.4.21253.5 | 2,624 | 5/24/2021 | |
6.0.0-preview.3.21201.13 | 11,674 | 4/8/2021 | |
6.0.0-preview.2.21154.6 | 2,019 | 3/11/2021 | |
6.0.0-preview.1.21103.6 | 3,094 | 2/12/2021 | |
5.0.17 | 511,028 | 5/10/2022 | |
5.0.16 | 70,510 | 4/11/2022 | |
5.0.15 | 153,914 | 3/8/2022 | |
5.0.14 | 146,144 | 2/8/2022 | |
5.0.13 | 485,725 | 12/14/2021 | |
5.0.12 | 495,840 | 11/7/2021 | |
5.0.11 | 2,606,361 | 10/12/2021 | |
5.0.10 | 3,726,457 | 9/14/2021 | |
5.0.9 | 871,733 | 8/10/2021 | |
5.0.8 | 1,049,792 | 7/13/2021 | |
5.0.7 | 1,335,513 | 6/8/2021 | |
5.0.6 | 902,193 | 5/11/2021 | |
5.0.5 | 908,936 | 4/6/2021 | |
5.0.4 | 856,854 | 3/9/2021 | |
5.0.3 | 1,047,890 | 2/9/2021 | |
5.0.2 | 702,021 | 1/12/2021 | |
5.0.1 | 570,567 | 12/8/2020 | |
5.0.0 | 1,894,206 | 11/9/2020 | |
5.0.0-rc.2.20475.17 | 18,466 | 10/13/2020 | |
5.0.0-rc.1.20451.17 | 12,356 | 9/14/2020 | |
5.0.0-preview.8.20414.8 | 3,719 | 8/25/2020 | |
5.0.0-preview.7.20365.19 | 3,742 | 7/21/2020 | |
5.0.0-preview.6.20312.15 | 4,365 | 6/25/2020 | |
5.0.0-preview.5.20279.2 | 1,301 | 6/10/2020 | |
5.0.0-preview.4.20257.10 | 5,612 | 5/18/2020 | |
5.0.0-preview.3.20215.14 | 2,666 | 4/23/2020 | |
5.0.0-preview.2.20167.3 | 2,037 | 4/2/2020 | |
5.0.0-preview.1.20124.5 | 2,205 | 3/16/2020 | |
3.1.32 | 437,694 | 12/13/2022 | |
3.1.31 | 51,113 | 11/8/2022 | |
3.1.30 | 34,173 | 10/11/2022 | |
3.1.29 | 38,086 | 9/13/2022 | |
3.1.28 | 57,697 | 8/9/2022 | |
3.1.27 | 60,879 | 7/12/2022 | |
3.1.26 | 72,195 | 6/14/2022 | |
3.1.25 | 73,623 | 5/10/2022 | |
3.1.24 | 70,511 | 4/11/2022 | |
3.1.23 | 107,943 | 3/8/2022 | |
3.1.22 | 772,762 | 12/14/2021 | |
3.1.21 | 192,845 | 11/7/2021 | |
3.1.20 | 200,068 | 10/11/2021 | |
3.1.19 | 258,377 | 9/14/2021 | |
3.1.18 | 444,990 | 8/10/2021 | |
3.1.17 | 289,766 | 7/13/2021 | |
3.1.16 | 350,685 | 6/8/2021 | |
3.1.15 | 478,449 | 5/11/2021 | |
3.1.14 | 410,180 | 4/6/2021 | |
3.1.13 | 368,506 | 3/9/2021 | |
3.1.12 | 406,163 | 2/9/2021 | |
3.1.11 | 464,087 | 1/12/2021 | |
3.1.10 | 1,227,074 | 11/9/2020 | |
3.1.9 | 1,255,057 | 10/13/2020 | |
3.1.8 | 1,290,578 | 9/8/2020 | |
3.1.7 | 864,013 | 8/11/2020 | |
3.1.6 | 1,940,433 | 7/14/2020 | |
3.1.5 | 2,224,756 | 6/9/2020 | |
3.1.4 | 1,289,728 | 5/12/2020 | |
3.1.3 | 2,584,828 | 3/24/2020 | |
3.1.2 | 1,049,494 | 2/18/2020 | |
3.1.1 | 1,469,854 | 1/14/2020 | |
3.1.0 | 3,801,801 | 12/3/2019 | |
3.1.0-preview3.19555.2 | 5,551 | 11/13/2019 | |
3.1.0-preview2.19528.8 | 1,044 | 11/1/2019 | |
3.1.0-preview1.19508.20 | 1,199 | 10/15/2019 | |
3.0.3 | 73,327 | 2/18/2020 | |
3.0.2 | 37,189 | 1/14/2020 | |
3.0.0 | 4,572,115 | 9/23/2019 | |
3.0.0-rc1.19457.4 | 4,433 | 9/16/2019 | |
3.0.0-preview9.19424.4 | 16,701 | 9/4/2019 | |
3.0.0-preview8.19405.7 | 10,555 | 8/13/2019 | |
3.0.0-preview7.19365.7 | 5,786 | 7/23/2019 | |
3.0.0-preview6.19307.2 | 5,896 | 6/12/2019 | |
3.0.0-preview5-19227-01 | 3,523 | 5/6/2019 | |
3.0.0-preview4-19216-03 | 802 | 4/18/2019 | |
3.0.0-preview3-19153-02 | 1,637 | 3/6/2019 |