auto update browser on cshtml save - working with webpack #292

Closed
opened 2025-08-09 17:15:44 +00:00 by fergalmoran · 0 comments
Owner

Originally created by @JohnGoldsmith on 12/5/2017

I've got webpack and HMR working nicely with an ASP.NET Core 2 project (thanks to the docs here). SCSS changes bubble up nicely in the browser without a full page reload.

What I'm not clear on is how to include various views (cshtml) to this. Is this something I should be looking to webpack to help with or should is there an alternative option here?

My intitial thought was to use Mads Kristensen's Browser Reload but now, even though I get cshtml changes auto reloading the page, changes to the webpack-handled scss also generate a page reload, which is obviously a backwards step.

Has anyone got these two to work together correctly?

*Originally created by @JohnGoldsmith on 12/5/2017* I've got webpack and HMR working nicely with an ASP.NET Core 2 project (thanks to the docs here). SCSS changes bubble up nicely in the browser without a full page reload. What I'm not clear on is how to include various views (cshtml) to this. Is this something I should be looking to webpack to help with or should is there an alternative option here? My intitial thought was to use [Mads Kristensen's Browser Reload](https://marketplace.visualstudio.com/items?itemName=MadsKristensen.BrowserReloadonSave#overview) but now, even though I get cshtml changes auto reloading the page, changes to the webpack-handled scss also generate a page reload, which is obviously a backwards step. Has anyone got these two to work together correctly?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/JavaScriptServices#292
No description provided.