Skip to content

Commit

Permalink
Speculative fix for #568 (#569)
Browse files Browse the repository at this point in the history
* Speculative fix for #568

* Remove default of setting isolatedModules to true when in transpileOnly mode

Not useful for when using ts-loader with fork-ts-checker-webpack-plugin.  Can still be set manually with tsconfig.json if desired and so arguably not a breaking change
  • Loading branch information
johnnyreilly authored Jul 1, 2017
1 parent 767f796 commit 7004e17
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
5 changes: 0 additions & 5 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,6 @@ export function getConfigFile(
configFile.config.compilerOptions = Object.assign({},
configFile.config.compilerOptions,
loaderOptions.compilerOptions);

// do any necessary config massaging
if (loaderOptions.transpileOnly) {
configFile.config.compilerOptions.isolatedModules = true;
}
}

return {
Expand Down
4 changes: 2 additions & 2 deletions src/servicesHost.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ function makeServicesHost(
directoryExists: compiler.sys ? (<any> compiler.sys).directoryExists : undefined,

// The following three methods are necessary for @types resolution from TS 2.4.1 onwards see: https://github.com/Microsoft/TypeScript/issues/16772
fileExists: moduleResolutionHost.fileExists,
readFile: moduleResolutionHost.readFile,
fileExists: compiler.sys ? (<any> compiler.sys).fileExists : undefined,
readFile: compiler.sys ? (<any> compiler.sys).readFile : undefined,
readDirectory: compiler.sys ? (<any> compiler.sys).readDirectory : undefined,

getCurrentDirectory: () => process.cwd(),
Expand Down

0 comments on commit 7004e17

Please sign in to comment.