abp icon indicating copy to clipboard operation
abp copied to clipboard

Overriding .Razor file in v3.2.0-rc.2 does not seem to work

Open rlavaud opened this issue 6 years ago • 5 comments

Hi I don't know if we have to do something different with Blazor webassembly to override .razor files. In MVC all we have to do was replace a file in correct path and setup embedding. I created a Blazor template file, copied the MainLayout.razor into Themes/Pages then added @using Volo.Abp.AspNetCore.Components.WebAssembly.BasicTheme.Themes.Basic so that it would compile. When I run the application the new layout is not in effect. I also added the Volo.Abp.VirtualFileSystem package to the blazor app along the dependsOn Am I missing something?

rlavaud avatar Sep 24 '20 22:09 rlavaud

hi @cotur Does the Blazor page support to override for now?

maliming avatar Sep 25 '20 01:09 maliming

Hi,

This was the my first question when we started to develop razor modules. 😃

Unfortunately overriding .razor page is not possible for now. Please follow our blog posts, we will share it directly if we find a way about how to do it.

cotur avatar Sep 25 '20 14:09 cotur

So for now if I want to make changes to a UI in a Blazor module, the only way would be to recreate the whole module project in my own solution. For example to change the layout, I should either create a theme with a copy of ThemeBasic and make modification to my local copy. I can't think of another approach. Also @cotur would you mind sharing some the technical challenges with the community when you have some time?

rlavaud avatar Sep 25 '20 20:09 rlavaud

@rlavaud of course, we have a lot of things to share for Blazor. :)

In 1-2 milestone section, most of things will become more stable, then we share articles and documentations for them.

cotur avatar Oct 01 '20 10:10 cotur

Thanks I will be waiting.

rlavaud avatar Oct 01 '20 15:10 rlavaud