Open
Description
Is there an existing issue for this?
- I have searched the existing issues
Describe the bug
In .NET 9, updating a .css
file inside a referenced Razor class library no longer triggers a page refresh or hot reload in the browser.
This worked correctly in .NET 8, where making changes to a CSS file in a Razor class library (e.g. shared.css
) would automatically update the browser.
Expected Behavior
The web page should reload / refresh and the changes should be reflected without having to manually refresh the current webpage
Steps To Reproduce
- Clone the repro: Hot reload repro
- dotnet watch the
HotReload
project - Modify
wwwroot/shared.css
in theHotReload.RazorClassLibrary
project - Observe: No hot reload or browser refresh
- Switch to the
dotnet8
branch - Repeat steps 2–4
- Observe: Hot reload and browser refresh work correctly
Exceptions (if any)
No response
.NET Version
dotnet 9.0.202
Anything else?
OS: Macos Sequoia 15.3
IDE: Rider 2024.3.6 - Bug also verified using vscode