I have a Blazor Interactive Server deployed on a server and some times the theme .css does not load when i visit the website. Not sure if that's a Radzen problem or server configuration problem but I only get this error in Radzen.Blazor/css/dark.css, I load 4 more .css files and never had a problem with them.
GET https://website.com/_content/Radzen.Blazor/css/dark.css net::ERR_HTTP2_PROTOCOL_ERROR
I added this to head App.razor
<link rel="stylesheet" href="_content/Radzen.Blazor/css/dark.css">
and this to body App.razor
<script src="_content/Radzen.Blazor/Radzen.Blazor.js"></script>
Hi @wepih8,
The code seems correct. Does the problem happen always or at random? Is there any live URL where we can test?
I reproduced something when requesting the file with curl
. The file starts to load and then fails with
curl: (92) HTTP/2 stream 1 was not closed cleanly: INTERNAL_ERROR (err 2)
It looks as if your server drops the connection just for that file. What is stranger is that it happened once.
Here is a few things to try:
- Include the base version of dark.css -
<link rel="stylesheet" href="_content/Radzen.Blazor/css/dark-base.css">
. It is smaller and doesn't include bootstrap which you already seem to include.
- Try changing the order of CSS files - the only requirement for the theme is to be after bootstrap.css.