Skip to content

Commit

Permalink
Fix Windows compatibility (facebook#3232)
Browse files Browse the repository at this point in the history
* Windows compatibility

* Use regex for mutli-replace
  • Loading branch information
Timer authored Oct 3, 2017
1 parent f498547 commit 01a0d73
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 @@ -77,7 +77,9 @@ module.exports = function(proxy, allowedHost) {
// https://github.com/facebookincubator/create-react-app/issues/1065
watchOptions: {
ignored: new RegExp(
`^(?!${path.normalize(paths.appSrc + '/')}).+[\\/]node_modules[\\/]`,
`^(?!${path
.normalize(paths.appSrc + '/')
.replace(/[\\]+/g, '\\\\')}).+[\\\\/]node_modules[\\\\/]`,
'g'
),
},
Expand Down

0 comments on commit 01a0d73

Please sign in to comment.