[英]Shared CSS file blazor
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.
但是,如果您想添加一些可通過您的應用程序使用的共享 css,您可以通過編輯站點范圍的 css 文件來“以舊方式”進行操作。 使用 Blazor 模板,即wwwroot/css/site.css
用於服務器端或wwwroot/css/app.css
用於客戶端。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.