Skip to content

Commit 758f7aa

Browse files
committed
maint(Build): Restrict development server watcher only for files in the src directory.
This reduces the number of necessary file watchers and saves important system resources.
1 parent 3191eba commit 758f7aa

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

webpack/webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ module.exports = () => {
8383

8484
if (process.env.NODE_ENV === "development") {
8585
config.devServer.static.directory = path.resolve(__dirname, "../");
86+
config.devServer.watchFiles = ["src/"];
8687
// Add a strict Content-Security-Policy without 'unsafe-inline' to the dev
8788
// server for testing CSR issues.
8889
//config.devServer.headers["Content-Security-Policy"] =

0 commit comments

Comments
 (0)