I have created web application - Asp.Net MVC
in .NET Core
.
This application contains some Razor Views
but I would like to share these views to another application like for example with DLL or like middleware.
Here is some information about example with distribution Controllers
but around Views
nothing special - https://docs.microsoft.com/en-us/aspnet/core/mvc/advanced/app-parts
I've tried add Controller like this:
var assembly = typeof(Project.HomeController).GetTypeInfo().Assembly;
services.AddMvc()
.AddApplicationPart(assembly);
This works very well, but I don't know how add the Views.
How can I distribute the Razor Views
to another application? Is it way import them like a middleware to the MVC middleware
?