Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ env:
- TYPESCRIPT=typescript@2.1.5
- TYPESCRIPT=typescript@2.2.1
- TYPESCRIPT=typescript@2.3.1
- TYPESCRIPT=typescript@2.4.1
# - TYPESCRIPT=typescript@next
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
## v2.2.1 - NOT RELEASED YET

- [Report errors in JS(X) files when CheckJS is enabled](https://github.com/TypeStrong/ts-loader/pull/564) - thanks @schmuli!
- [Cater for change to @types acquisition strategy in TypeScript 2.4.1](https://github.com/TypeStrong/ts-loader/pull/566) - thanks @johnnyreilly

## v2.2.0

Expand Down
1 change: 1 addition & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ environment:
- TYPESCRIPT: typescript@2.1.5
- TYPESCRIPT: typescript@2.2.1
- TYPESCRIPT: typescript@2.3.1
- TYPESCRIPT: typescript@2.4.1
# - TYPESCRIPT: typescript@next
install:
- ps: Install-Product node $env:nodejs_version
Expand Down
6 changes: 6 additions & 0 deletions src/servicesHost.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ function makeServicesHost(
* For @types expansion, these two functions are needed.
*/
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,
readDirectory: compiler.sys ? (<any> compiler.sys).readDirectory : undefined,

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

getCompilationSettings: () => compilerOptions,
Expand Down