It is possible to load a RCL (Razor Component Library) to Blazor WebAssembly dynamically?
I found this Loading an external .NET Standard 2.0 assembly with blazor to load a standard classes
What I want is to develop a pluggable/extensible visual framework, where putting a dll in a ASP.NET Core Server folder where enought to access to that blazor component
Solution config:
- ASP.NET Core WebAPI project
- Blazor WebAssembly project
- RCL project 1 with some components
- RCL project 2 with another components
Steps:
- Open a Blazor Page and OnInitializedAsync() retreive some dll from WebAPI as binary
- Load binary to Assembly
- Reference the assembly and use it dynamically in the page
I finally develop a solution I want to share with you. A Module Manager witch allows you to load any outside component dynamically
Check it out here:
https://github.com/elgransan/BlazorPluginComponents
Some example code
Where the files are in the server