Questions tagged [webpack-hmr]

343 questions
3
votes
2 answers

Hot module replacement in angular 8

I am currently starting a new angular project, and I would like to implement HMR (Hot Module Replacement). I have done each and every step described in the tutorial, but I get the following errors: Using the latest angular version. Fresh project…
Tanasos
  • 3,928
  • 4
  • 33
  • 63
3
votes
1 answer

How to wait for app to close before starting a new instance with webpack hot module reload?

I'm using webpack hot module reload (hmr) for my nest.js application. The reload works but doesn't wait for the old instance to close fully (database connection, telegram bot,...) before starting up a new instance. This makes typeorm throw the…
Kim Kern
  • 54,283
  • 17
  • 197
  • 195
3
votes
1 answer

Configure Hot Module Reload for ElectronJS + Vue

I have the following repository where I would like to get Hot Module Reload to work. So far I am able to: start the app compile the app files and run a spectron test using the compiled files What I'd like to achieve is to alter the webpack…
joeyj
  • 535
  • 1
  • 6
  • 22
3
votes
1 answer

webpack HMR not loading css

A simple webpack configuration but not working : var path = require("path"); var HtmlWebpackPlugin = require('html-webpack-plugin'); module.exports = { module: { rules: [ { test:/\.css$/, …
freezix
  • 83
  • 4
3
votes
1 answer

webpack dev server not building and reloading index.html

I am using webpack v4 right now trying to add webpack-dev-server to my project. The Issue I am facing here is when i run the webpack-dev-server command my it opens a local server in my default browser but not serving the compiled assets and also is…
3
votes
2 answers

Publishing on Azure a asp.net Core 2.0 WebApp with ReactJS on Development mode

I've got a web app with asp.net Core 2.0 and ReactJS. If I publish the app in Azure in a Production environment everything goes right. But when I try to change it to Development (adding on the Application Settings the key ASPNETCORE_ENVIRONMENT with…
3
votes
0 answers

Rails/Webpacker and BrowserSync for CSS

I would like to use both BrowserSync features and Rails/Webpacker (with Vue and Rails 5.1). My setup is working for Javascript from webpack-dev-server. The SCSS/CSS is compiling correctly and writing to disk. Browser Sync reloads on HTML file…
3
votes
0 answers

Use webpack-dev-server with multiple entries and HMR

I have 3 entries in my webpack.config.js that generate 3 different HTML files. I do this so I can host them on separate domains: index.html = http://app.local site.html = http://site.local forms.html = http://forms.local Right now I have a…
3
votes
0 answers

Webpack - browser refresh on a file change which isn't module

I want to refresh page when I change (save) ./src/*.js files in my code editor. The problem is I'm not importing this files in my entry point (with import in index.js) but I'm joining them with a plugin so code is in browser's global scope rather…
Jan Pi
  • 167
  • 2
  • 13
3
votes
1 answer

Is it possible to HMR a resource on a remote server?

I'm developing a typescript react app on salesforce and have a bit of a unique workflow use-case. In order to easy the burden of deployments every time I made a change to my app, I have a switch to load the js bundle from localhost in my salesforce…
NSjonas
  • 10,693
  • 9
  • 66
  • 92
3
votes
1 answer

Webpack Hot Module Replacement always doing full page reload with PHP built-in server

I am trying to use Webpack Hot Module Replacement for my CSS. I run the PHP built-in server (php -S localhost:8000 -t .) to load the following index.php file, which is at the root of my project :
Cyrille
  • 1,078
  • 1
  • 10
  • 24
3
votes
1 answer

React Hot Reload with React-hot-loader 3, React-router 4, and Webpack-hot-middleware

I am trying to make React-hot-loader 3 work with React-hot-loader 3, React-router 4 and Webpack-hot-middleware (last version, 2.18.2). Here is my server.js: const express = require('express'); const bodyParser = require('body-parser'); const…
adrienharnay
  • 795
  • 2
  • 9
  • 27
3
votes
0 answers

Webpack Hot Module Replacement for KnockoutJS

I'm trying to get HMR to work for my knockout application and currently struggling to get HMR to reload whenever I change something inside the viewModel itself, but anything outside the scope will…
Ali
  • 9,997
  • 20
  • 70
  • 105
3
votes
1 answer

Using webpack HMR (Hot Module replacement) without the webpack-dev-server

I implemented the HMR with webpack and it works ok. When I change something I see in the console that it has updated but since I am using it for the server bundle I was wondering hot to send signal to browser to reload after HMR finishes, or better…
Igor-Vuk
  • 3,551
  • 7
  • 30
  • 65
3
votes
0 answers

Webpack Hot Module Reloading not working

I am developing a React application, using Webpack and Hot Module Reloading. It used to work just fine, but some months ago it stopped working, and I have still not been able to find out why. What I think separates my issue from other issues I have…
Knut Marius
  • 1,588
  • 18
  • 40