Skip to content

Commit 8ae1349

Browse files
zaloxJørgen Sverre Lien Sellæg
authored andcommitted
fix crash of wds when trying to follow emacs lock files by ignoring them in file watcher.
closes #9056
1 parent 93241a0 commit 8ae1349

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

packages/react-dev-utils/ignoredFiles.js

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,15 @@ const path = require('path');
1111
const escape = require('escape-string-regexp');
1212

1313
module.exports = function ignoredFiles(appSrc) {
14-
return new RegExp(
15-
`^(?!${escape(
16-
path.normalize(appSrc + '/').replace(/[\\]+/g, '/')
17-
)}).+/node_modules/`,
18-
'g'
19-
);
14+
return [
15+
new RegExp(
16+
`^(?!${escape(
17+
path.normalize(appSrc + '/').replace(/[\\]+/g, '/'),
18+
)}).+/node_modules/`,
19+
'g',
20+
),
21+
'**/.#*',
22+
'**/*~',
23+
'**/#*#',
24+
];
2025
};

0 commit comments

Comments
 (0)