I create new .net 6 web application and CSS isolation work fine but when I add this line of code builder.Services.AddRazorPages().AddRazorRuntimeCompilation();
to my Program.cs all CSS isolation styles will disable automatically. What should I do? I found this post Problem with CSS Isolation when I use AddRazorRuntimeCompilation but it not work for me.
Asked
Active
Viewed 99 times
1

cutradition
- 11
- 1
-
This post has a proper explanation and a working solution: https://stackoverflow.com/questions/70257443/adding-addrazorruntimecompilation-to-the-container-in-net-core-6-will-break-t – Kappacake Sep 03 '22 at 10:19