Home:ALL Converter>Loading Razor Class Libraries as plugins

Loading Razor Class Libraries as plugins

Ask Time:2018-06-08T22:02:12         Author:Vahid Rassouli

Json Formatter

When using Razor Class Libraries with ASP.net core 2.1, if I add reference to the class library, it loads controllers, and views as expected. But the question is, how can I load this modules dynamically at runtime? I want to put modules at directory, which are not referenced at design time, and load them at the start up of the app. I tried to use Application Parts. But that way, controllers are loaded, but views are not discovered.

Author:Vahid Rassouli,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/50762385/loading-razor-class-libraries-as-plugins
yy