Skip to content

Commit

Permalink
chore(deps): switch to tinyglobby
Browse files Browse the repository at this point in the history
  • Loading branch information
benmccann committed Feb 18, 2025
1 parent f049c4c commit 7df738c
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 9 deletions.
4 changes: 2 additions & 2 deletions packages/plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@
"@graphql-tools/graphql-tag-pluck": "^8.3.4",
"@graphql-tools/utils": "^10.0.0",
"debug": "^4.3.4",
"fast-glob": "^3.2.12",
"graphql-config": "^5.1.3",
"graphql-depth-limit": "^1.1.0",
"lodash.lowercase": "^4.3.0"
"lodash.lowercase": "^4.3.0",
"tinyglobby": "^0.2.11"
},
"devDependencies": {
"@apollo/subgraph": "^2.9.3",
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin/src/documents.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import path from 'node:path';
import debugFactory from 'debug';
import fg from 'fast-glob';
import { globSync } from 'tinyglobby';
import { GraphQLProjectConfig } from 'graphql-config';
import { Source } from '@graphql-tools/utils';
import { ModuleCache } from './cache.js';
Expand Down Expand Up @@ -47,7 +47,7 @@ export const getDocuments = (project: GraphQLProjectConfig): Source[] => {
});
if (debug.enabled) {
debug('Loaded %d operations', documents.length);
const operationsPaths = fg.sync(project.documents as Pointer, { absolute: true });
const operationsPaths = globSync(project.documents as Pointer, { absolute: true, expandDirectories: false });
debug('Operations pointers %O', operationsPaths);
}
siblings = handleVirtualPath(documents);
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin/src/schema.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import debugFactory from 'debug';
import fg from 'fast-glob';
import { globSync } from 'tinyglobby';
import { BREAK, GraphQLSchema, visit } from 'graphql';
import { GraphQLProjectConfig } from 'graphql-config';
import { ModuleCache } from './cache.js';
Expand Down Expand Up @@ -57,7 +57,7 @@ export function getSchema(project: GraphQLProjectConfig): Schema {

if (debug.enabled) {
debug('Schema loaded: %o', schema instanceof GraphQLSchema);
const schemaPaths = fg.sync(project.schema as Pointer, { absolute: true });
const schemaPaths = globSync(project.schema as Pointer, { absolute: true, expandDirectories: false });
debug('Schema pointers %O', schemaPaths);
}
schemaCache.set(schemaKey, schema);
Expand Down
27 changes: 24 additions & 3 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7df738c

Please sign in to comment.