File tree Expand file tree Collapse file tree 1 file changed +22
-8
lines changed
packages/tailwindcss-language-server/src Expand file tree Collapse file tree 1 file changed +22
-8
lines changed Original file line number Diff line number Diff line change @@ -276,14 +276,10 @@ export class ProjectLocator {
276
276
277
277
private async findConfigs ( ) : Promise < ConfigEntry [ ] > {
278
278
// Look for config files and CSS files
279
- let files = await glob ( [ `**/${ CONFIG_GLOB } ` , `**/${ CSS_GLOB } ` ] , {
280
- cwd : this . base ,
281
- ignore : this . settings . tailwindCSS . files . exclude ,
282
- onlyFiles : true ,
283
- absolute : true ,
284
- suppressErrors : true ,
285
- dot : true ,
286
- concurrency : Math . max ( os . cpus ( ) . length , 1 ) ,
279
+ let files = await this . glob ( {
280
+ base : this . base ,
281
+ include : [ `**/${ CONFIG_GLOB } ` , `**/${ CSS_GLOB } ` ] ,
282
+ exclude : this . settings . tailwindCSS . files . exclude ,
287
283
} )
288
284
289
285
let realpaths = await Promise . all ( files . map ( ( file ) => fs . realpath ( file ) ) )
@@ -516,6 +512,24 @@ export class ProjectLocator {
516
512
isDefaultVersion : true ,
517
513
}
518
514
}
515
+
516
+ private async glob ( options : {
517
+ base : string
518
+ include : string [ ]
519
+ exclude : string [ ]
520
+ } ) : Promise < string [ ] > {
521
+ let files = await glob ( options . include , {
522
+ cwd : options . base ,
523
+ ignore : options . exclude ,
524
+ onlyFiles : true ,
525
+ absolute : true ,
526
+ suppressErrors : true ,
527
+ dot : true ,
528
+ concurrency : Math . max ( os . cpus ( ) . length , 1 ) ,
529
+ } )
530
+
531
+ return files
532
+ }
519
533
}
520
534
521
535
function contentSelectorsFromConfig (
You can’t perform that action at this time.
0 commit comments