Open dodyg opened 8 years ago
if we are in aspnetcore - you will either be using RazorPages model or MVC model. Both RazorPages & MVC model have Razor engine as the View engine. If we have to showcase Razor outside of MVC - then it has to be non aspnetcore project types. which will defeat the purpose of practical-aspnetcore ?
thoughts ?
Razor Template Engine is useful beyond just generating string for the view. You can use it to in theory to generate static files or generate emails. These are activities that are within the realm of people using ASP.NET Core for. The problem is that Razor Template Engine is too highly coupled with MVC which creates problems.
Razor will have a new architecture in .NET 6. It's an opportunity to take a look at this idea once again to see if it is better.
https://github.com/aspnet/Entropy/tree/master/samples/Mvc.RenderViewToString