The strengths of the new .NET5 CSS isolation feature (placing a css file "below" your razor file), is that the css is NOT shared between pages/components making them easier to develop and contained/bundled to the specific component.
If you however want to add some shared css that would be available thru out your app, you would do it "the old fashion way" by editing the site-wide css file. Using the Blazor templates, that would be wwwroot/css/site.css
for server side or wwwroot/css/app.css
for client side.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.