Skip to content

Commit aff605e

Browse files
opichalsblakeembrey
authored andcommittedJul 22, 2016
Declarations update independent of compiler.watchFileSystem (#167)
Uses `watching.compiler.fileTimestamps` which is set directly in the compiler. See https://github.com/webpack/webpack/blob/master/lib/Compiler.js#L105. Fixes the #155 when using the webpack.OldNodeWatchFileSystem.
1 parent 26481d5 commit aff605e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed
 

‎index.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -508,7 +508,8 @@ function ensureTypeScriptInstance(loaderOptions: LoaderOptions, loader: any): {
508508

509509
// manually update changed files
510510
loader._compiler.plugin("watch-run", (watching, cb) => {
511-
var mtimes = watching.compiler.watchFileSystem.watcher.mtimes;
511+
var mtimes = watching.compiler.fileTimestamps ||
512+
watching.compiler.watchFileSystem.watcher.mtimes;
512513
Object.keys(mtimes)
513514
.filter(filePath => !!filePath.match(/\.tsx?$|\.jsx?$/))
514515
.forEach(filePath => {

0 commit comments

Comments
 (0)
Please sign in to comment.