Skip to content

Commit

Permalink
Timerify resolveModuleNames (#673)
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Jun 12, 2024
1 parent c170aeb commit 9f2077c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/knip/src/typescript/resolveModuleNames.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { existsSync } from 'node:fs';
import { isBuiltin } from 'node:module';
import ts from 'typescript';
import { DEFAULT_EXTENSIONS, FOREIGN_FILE_EXTENSIONS } from '../constants.js';
import { timerify } from '../util/Performance.js';
import { sanitizeSpecifier } from '../util/modules.js';
import { dirname, extname, isAbsolute, isInNodeModules, join } from '../util/path.js';
import { resolveSync } from '../util/resolve.js';
Expand Down Expand Up @@ -139,5 +140,5 @@ export function createCustomModuleResolver(
return resolvedModule;
}

return resolveModuleNames;
return timerify(resolveModuleNames);
}

0 comments on commit 9f2077c

Please sign in to comment.