@@ -2,8 +2,8 @@ import { promises as fsPromises, readFileSync, statSync } from 'fs';
22import { createRequire } from 'module' ;
33import { extname , join } from 'path' ;
44import { cwd } from 'process' ;
5- import globby , { GlobbyOptions , sync as globbySync } from 'globby' ;
65import { DocumentNode , parse } from 'graphql' ;
6+ import { GlobOptions , globSync , glob as tinyglobby } from 'tinyglobby' ;
77import unixify from 'unixify' ;
88
99const { readFile, stat } = fsPromises ;
@@ -63,8 +63,8 @@ async function isDirectory(path: string) {
6363 }
6464}
6565
66- function scanForFilesSync ( globStr : string | string [ ] , globOptions : GlobbyOptions = { } ) : string [ ] {
67- return globbySync ( globStr , { absolute : true , ...globOptions } ) ;
66+ function scanForFilesSync ( globStr : string | string [ ] , globOptions : GlobOptions = { } ) : string [ ] {
67+ return globSync ( globStr , { absolute : true , ...globOptions } ) ;
6868}
6969
7070function formatExtension ( extension : string ) : string {
@@ -98,8 +98,8 @@ export interface LoadFilesOptions {
9898 useRequire ?: boolean ;
9999 // An alternative to `require` to use if `require` would be used to load a file
100100 requireMethod ?: any ;
101- // Additional options to pass to globby
102- globOptions ?: GlobbyOptions ;
101+ // Additional options to pass to tinyglobby
102+ globOptions ?: GlobOptions ;
103103 // Named exports to extract from each file. Defaults to ['typeDefs', 'schema']
104104 exportNames ?: string [ ] ;
105105 // Load files from nested directories. Set to `false` to only search the top-level directory.
@@ -183,9 +183,9 @@ export function loadFilesSync<T = any>(
183183
184184async function scanForFiles (
185185 globStr : string | string [ ] ,
186- globOptions : GlobbyOptions = { } ,
186+ globOptions : GlobOptions = { } ,
187187) : Promise < string [ ] > {
188- return globby ( globStr , { absolute : true , ...globOptions } ) ;
188+ return tinyglobby ( globStr , { absolute : true , ...globOptions } ) ;
189189}
190190
191191const checkExtension = (
0 commit comments