@@ -25,14 +25,10 @@ type Result = {
25
25
fileCountWithProblems : number ;
26
26
} ;
27
27
28
- async function openAllDocuments (
29
- workspaceUri : URI ,
30
- filePathsToIgnore : string [ ] ,
31
- svelteCheck : SvelteCheck
32
- ) {
28
+ async function openAllDocuments ( workspaceUri : URI , svelteCheck : SvelteCheck ) {
33
29
const files = await glob ( '**/*.svelte' , {
34
30
cwd : workspaceUri . fsPath ,
35
- ignore : [ 'node_modules/**' ] . concat ( filePathsToIgnore . map ( ( ignore ) => ` ${ ignore } /**` ) )
31
+ ignore : [ 'node_modules/**' ]
36
32
} ) ;
37
33
const absFilePaths = files . map ( ( f ) => path . resolve ( workspaceUri . fsPath , f ) ) ;
38
34
@@ -110,13 +106,12 @@ class DiagnosticsWatcher {
110
106
private workspaceUri : URI ,
111
107
private svelteCheck : SvelteCheck ,
112
108
private writer : Writer ,
113
- filePathsToIgnore : string [ ] ,
114
109
ignoreInitialAdd : boolean
115
110
) {
116
111
watch ( `${ workspaceUri . fsPath } /**/*.{svelte,d.ts,ts,js,jsx,tsx,mjs,cjs,mts,cts}` , {
117
- ignored : [ 'node_modules' , 'vite.config.{js,ts}.timestamp-*' ]
118
- . concat ( filePathsToIgnore )
119
- . map ( ( ignore ) => path . join ( workspaceUri . fsPath , ignore ) ) ,
112
+ ignored : [ 'node_modules' , 'vite.config.{js,ts}.timestamp-*' ] . map ( ( ignore ) =>
113
+ path . join ( workspaceUri . fsPath , ignore )
114
+ ) ,
120
115
ignoreInitial : ignoreInitialAdd
121
116
} )
122
117
. on ( 'add' , ( path ) => this . updateDocument ( path , true ) )
@@ -198,14 +193,13 @@ parseOptions(async (opts) => {
198
193
opts . workspaceUri ,
199
194
new SvelteCheck ( opts . workspaceUri . fsPath , svelteCheckOptions ) ,
200
195
writer ,
201
- opts . filePathsToIgnore ,
202
196
! ! opts . tsconfig
203
197
) ;
204
198
} else {
205
199
const svelteCheck = new SvelteCheck ( opts . workspaceUri . fsPath , svelteCheckOptions ) ;
206
200
207
201
if ( ! opts . tsconfig ) {
208
- await openAllDocuments ( opts . workspaceUri , opts . filePathsToIgnore , svelteCheck ) ;
202
+ await openAllDocuments ( opts . workspaceUri , svelteCheck ) ;
209
203
}
210
204
const result = await getDiagnostics ( opts . workspaceUri , writer , svelteCheck ) ;
211
205
if (
0 commit comments