-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
Description
The linter runs for a very long time if the "import/no-cycle" rule is enabled on a large project with typescript. I think the problem is that eslint does not cache all modules. For example, these files will always be parsed again:
- https://github.com/aws/aws-sdk-js/blob/master/clients/all.d.ts
- https://unpkg.com/browse/[email protected]/typings.d.ts
Minimal repository for reproduce: https://github.com/stenin-nikita/eslint-plugin-import-bug
Possible solution
This line
eslint-plugin-import/src/ExportMap.js
Line 349 in 68cea3e
if (exportMap == null) return null; |
replace with:
if (exportMap == null) {
exportCache.set(cacheKey, null);
return null;
}
Locally, this change reduced the check time from 20 to 4 minutes for me
Metadata
Metadata
Assignees
Labels
No labels