diff --git a/src/checks/noDependencyProblems/noUnusedDependencies.ts b/src/checks/noDependencyProblems/noUnusedDependencies.ts index 8c3b688b..b39575ae 100644 --- a/src/checks/noDependencyProblems/noUnusedDependencies.ts +++ b/src/checks/noDependencyProblems/noUnusedDependencies.ts @@ -58,7 +58,23 @@ export default async function noUnusedAndMissingDependencies() { try { await execaCommand( - `${preflightBinPath}/depcheck --ignores="${ignoredPackagePatterns}"`, + `${preflightBinPath}/depcheck --ignores="${ignoredPackagePatterns}" --parsers="${ + // TODO: Remove this once depcheck PR is published: + // https://github.com/depcheck/depcheck/pull/773#issuecomment-1649749599 + [ + '**/*.js:jsx', + '**/*.mjs:jsx', + '**/*.cjs:jsx', + '**/*.jsx:jsx', + '**/*.graphql:graphql', + '**/*.cts:typescript', + '**/*.mts:typescript', + '**/*.ts:typescript', + '**/*.tsx:typescript', + '**/*.sass:sass', + '**/*.scss:sass', + ].join(',') + }"`, ); } catch (error) { const { stdout } = error as { stdout: string };