You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enabling the eslint-bulk-suppressions patch slows down eslint substantially by introducing many file system accesses during linter execution. Lint rule execution should ideally not touch the file system once the source file has been read.
Repro steps
Enable the eslint-bulk-suppressions patch, run linting.
Expected result:
Exactly one file system access from the feature, to read the .eslint-bulk-suppressions.json file from a known computed path.
Actual result:
For every unique directory containing a file being linted, the eslint-bulk-suppressions patch probes the file system looking for .eslintrc.cjs or .eslintrc.js files.
Details
Considering that the eslint-bulk-suppressions patch is applied by invoking it from the project's .eslintrc.js file, it should be trivial to either pass in __filename to a function returned from the patch object, or else read the path to the .eslintrc.js file from the NodeJS require stack.
Standard questions
Please answer these questions to help us investigate your issue more quickly:
Question
Answer
@rushstack/eslint-config version?
1.10.4
Operating system?
Linux
Would you consider contributing a PR?
Yes
TypeScript compiler version?
5.3.3
Node.js version (node -v)?
18.19.1
The text was updated successfully, but these errors were encountered:
Summary
Enabling the eslint-bulk-suppressions patch slows down eslint substantially by introducing many file system accesses during linter execution. Lint rule execution should ideally not touch the file system once the source file has been read.
Repro steps
Enable the
eslint-bulk-suppressions
patch, run linting.Expected result:
Exactly one file system access from the feature, to read the
.eslint-bulk-suppressions.json
file from a known computed path.Actual result:
For every unique directory containing a file being linted, the eslint-bulk-suppressions patch probes the file system looking for
.eslintrc.cjs
or.eslintrc.js
files.Details
Considering that the eslint-bulk-suppressions patch is applied by invoking it from the project's
.eslintrc.js
file, it should be trivial to either pass in__filename
to a function returned from the patch object, or else read the path to the.eslintrc.js
file from the NodeJS require stack.Standard questions
Please answer these questions to help us investigate your issue more quickly:
@rushstack/eslint-config
version?node -v
)?The text was updated successfully, but these errors were encountered: