Hi @Hassan Raza Khan,
After testing, the issue is related to the project name, you are using Sample Blazor App
and issue occurs. If using SampleBlazorApp
, it will works fine.
Reason:
In App.razor file, we can find it will use this line, then the url will be https://localhost:7298/Sample%20Blazor%20App.styles.css
.
If there are no special characters (spaces) when naming, you will not encounter this problem.
<link rel="stylesheet" href="Sample Blazor App.styles.css" />
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Best regards,
Jason