Skip to content

Commit

Permalink
Allow the dev server to watch for changes in src/node_modules
Browse files Browse the repository at this point in the history
  • Loading branch information
xjlim committed Oct 2, 2017
1 parent c003583 commit 80de217
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/react-scripts/config/webpackDevServer.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,10 @@ module.exports = function(proxy, allowedHost) {
quiet: true,
// Reportedly, this avoids CPU overload on some systems.
// https://github.com/facebookincubator/create-react-app/issues/293
// src/node_modules is not ignored to support absolute imports
// https://github.com/facebookincubator/create-react-app/issues/1065
watchOptions: {
ignored: /node_modules/,
ignored: new RegExp(`^(?!${paths.appSrc})*[\\\/]node_modules[\\\/]`, 'g'),
},
// Enable HTTPS if the HTTPS environment variable is set to 'true'
https: protocol === 'https',
Expand Down

0 comments on commit 80de217

Please sign in to comment.