- Operating System: Windows (Server 2019)
- Node Version: 10.15.0
- NPM Version: 6.4.1
- webpack Version: 4.32.2
- webpack-dev-server Version: 3.4.1
Code
// main/webpack.config.js
const HtmlWebpackPlugin = require('html-webpack-plugin');
const baseUrl = "/";
/** @type {() => import("webpack").Configuration} */
module.exports = () => ({
plugins: [
new HtmlWebpackPlugin({
template: "index.ejs",
metadata: { baseUrl }
})
]
})
// main/src/index.js
const {Service} = require("service"); // a dependency from a local node module
const div = document.createElement("div");
div.innerText = new Service().method();
document.querySelector("body").appendChild(div);
Expected Behavior
When any changes occur in the node_modules, webpack-dev-server should trigger a new build.
Actual Behavior
It is not happening after I upgraded to the latest [email protected]. With the earler version of 3.3.1 it was working perfectly. If the fix is non-trivial, are there better workarounds rather than pinning the version?
For Bugs; How can we reproduce the behavior?
I have created the repo https://github.com/Sayan751/webpack-reloading-issue to demonstrate this problem. The steps to reproduce the problem is detailed there.
For Features; What is the motivation and/or use-case for the feature?
Code
Expected Behavior
When any changes occur in the
node_modules,webpack-dev-servershould trigger a new build.Actual Behavior
It is not happening after I upgraded to the latest
[email protected]. With the earler version of3.3.1it was working perfectly. If the fix is non-trivial, are there better workarounds rather than pinning the version?For Bugs; How can we reproduce the behavior?
I have created the repo https://github.com/Sayan751/webpack-reloading-issue to demonstrate this problem. The steps to reproduce the problem is detailed there.
For Features; What is the motivation and/or use-case for the feature?