Update only pieces that have been modified using Webpack.watch ()?

I have a webpack assembly that uses the watch () method to continuously rebuild my javascript as I work. I also have an observer that uploads modified JS files to a remote server.

Now, when I change ANY file, it will recompile ALL files. Therefore, even if one fragment changes, it will update everything, including the provider file and other unrelated packages, fragments, etc.

Is there a way in Webpack to only recompile the changed files and change the dependencies?

Here is an example of my webpack build code:

var compiler = webpack(require('./webpack.config.js')); compiler.watch({ aggregateTimeout: 300, // wait so long for more changes poll: true }, function(err, stats) { console.log(stats); }); 
+7
javascript build webpack gulp
source share

No one has answered this question yet.

See related questions:

4523
"Thinking in AngularJS" if I have jQuery background?
2614
How to change an element class using JavaScript?
2406
Round to no more than 2 decimal places (only if necessary)
1835
How to update each dependency in package.json to the latest version?
fifteen
Webpack with two common pieces: one exported, one local
5
Understand Webpack Exit
3
Lazy-load only unloaded-chunk is different from webpack
one
provider web package regenerates unchanged
0
Disable blocking / caching of JSON files, while ignoring them
0
webpack --watch is not working properly