File tree 1 file changed +4
-3
lines changed
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -3,8 +3,7 @@ import * as ts from "typescript";
3
3
import * as fs from "fs" ;
4
4
import * as path from "path" ;
5
5
6
- declare type CONFIG_CACHE < T > = { [ file : string ] : T } ;
7
- const TSCONFIG_CACHE : CONFIG_CACHE < ts . ParsedCommandLine > = { } ;
6
+ const TSCONFIG_CACHE : { [ filePath : string ] : ts . ParsedCommandLine ; } = { } ;
8
7
9
8
export function createDefaultFormatCodeSettings ( ) : ts . FormatCodeSettings {
10
9
@@ -52,7 +51,9 @@ export function readFilesFromTsconfig(configPath: string): string[] {
52
51
}
53
52
54
53
export function readTsconfig ( configPath : string ) : ts . ParsedCommandLine {
55
- if ( TSCONFIG_CACHE [ configPath ] ) return TSCONFIG_CACHE [ configPath ] ;
54
+ if ( TSCONFIG_CACHE [ configPath ] ) {
55
+ return TSCONFIG_CACHE [ configPath ] ;
56
+ }
56
57
57
58
// for `extends` support. It supported from TypeScript 2.1.1.
58
59
// `& { readFile(path: string): string; }` is backword compat for TypeScript compiler 2.0.3 support.
You can’t perform that action at this time.
0 commit comments