File tree Expand file tree Collapse file tree 4 files changed +9
-16
lines changed
nodeModulesMeaningfulErrorWhenImportingTs Expand file tree Collapse file tree 4 files changed +9
-16
lines changed Original file line number Diff line number Diff line change @@ -96,8 +96,7 @@ export function makeServicesHost(
96
96
97
97
getProjectReferences : ( ) => projectReferences ,
98
98
99
- getScriptFileNames : ( ) =>
100
- [ ...files . keys ( ) ] . filter ( filePath => filePath . match ( scriptRegex ) ) ,
99
+ getScriptFileNames : ( ) => Array . from ( instance . rootFileNames ) ,
101
100
102
101
getScriptVersion : ( fileName : string ) => {
103
102
fileName = path . normalize ( fileName ) ;
@@ -351,7 +350,7 @@ export function makeWatchHost(
351
350
return watchHost ;
352
351
353
352
function getRootFileNames ( ) {
354
- return [ ... files . keys ( ) ] . filter ( filePath => filePath . match ( scriptRegex ) ) ;
353
+ return Array . from ( instance . rootFileNames ) ;
355
354
}
356
355
357
356
function readFileWithCachingText ( fileName : string , encoding ?: string ) {
Original file line number Diff line number Diff line change @@ -259,7 +259,11 @@ export function isRootFileOrExempt(
259
259
fileName : string ,
260
260
instance : TSInstance
261
261
) : boolean {
262
- if ( instance . rootFileNames . has ( fileName ) ) {
262
+ // node_modules checking handled separately, later
263
+ if (
264
+ instance . rootFileNames . has ( fileName ) ||
265
+ fileName . indexOf ( 'node_modules' ) > - 1
266
+ ) {
263
267
return true ;
264
268
}
265
269
Original file line number Diff line number Diff line change 1
1
{
2
2
"compilerOptions" : {
3
- },
4
- "files" : [
5
- " index.vue.ts"
6
- ]
3
+ }
7
4
}
Original file line number Diff line number Diff line change 1
- {
2
- "compilerOptions" : {
3
- "include" : [
4
- " node_modules" ,
5
- " app.ts"
6
- ]
7
- }
8
- }
1
+ {}
You can’t perform that action at this time.
0 commit comments