Skip to content

Commit 5fa7bec

Browse files
author
Zhengbo Li
committed
revert back to polling watching for approaching release
1 parent e675744 commit 5fa7bec

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/compiler/sys.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ namespace ts {
352352
// to increase the chunk size or decrease the interval
353353
// time dynamically to match the large reference set?
354354
const pollingWatchedFileSet = createPollingWatchedFileSet();
355-
const watchedFileSet = createWatchedFileSet();
355+
// const watchedFileSet = createWatchedFileSet();
356356

357357
function isNode4OrLater(): Boolean {
358358
return parseInt(process.version.charAt(1)) >= 4;
@@ -456,7 +456,8 @@ namespace ts {
456456
// and is more efficient than `fs.watchFile` (ref: https://github.com/nodejs/node/pull/2649
457457
// and https://github.com/Microsoft/TypeScript/issues/4643), therefore
458458
// if the current node.js version is newer than 4, use `fs.watch` instead.
459-
let fileSet = isNode4OrLater() ? watchedFileSet : pollingWatchedFileSet;
459+
// let fileSet = isNode4OrLater() ? watchedFileSet : pollingWatchedFileSet;
460+
let fileSet = pollingWatchedFileSet;
460461
const watchedFile = fileSet.addFile(fileName, callback);
461462
return {
462463
close: () => fileSet.removeFile(watchedFile)

0 commit comments

Comments
 (0)