[Bug]: ESLint lintDirtyModulesOnly
not working properly, still lints everything
#7748
Labels
Milestone
lintDirtyModulesOnly
not working properly, still lints everything
#7748
System Info
System:
OS: macOS 14.6.1
CPU: (10) arm64 Apple M1 Max
Memory: 631.08 MB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.14.0 - ~/.nvm/versions/node/v20.14.0/bin/node
Yarn: 1.22.22 - ~/.nvm/versions/node/v20.14.0/bin/yarn
npm: 10.8.2 - ~/.nvm/versions/node/v20.14.0/bin/npm
pnpm: 7.28.0 - ~/Library/pnpm/pnpm
bun: 1.1.8 - ~/.bun/bin/bun
Browsers:
Brave Browser: 126.1.67.123
Chrome: 128.0.6613.113
Edge: 128.0.2739.54
Safari: 17.6
npmPackages:
@rspack/cli: 1.0.0 => 1.0.0
@rspack/core: 1.0.0 => 1.0.0
Details
Might be related to #6432
Even if
lintDirtyModulesOnly
is enabled, it runs ESLint on all files. The expected behaviour (which seems to work well with Webpack) is to run the linter on the modified file only.It's a negligible difference for a small repo like
rspack-repro
, but in large repos, it causes HMR to reload in multiple seconds, instead of <1sec.Currently, modifying a single file will run the linter on all of them:
Expected (when using eslint-webpack-plugin):
Reproduce link
https://github.com/markmssd/rspack-repro/tree/eslint-warnings
Reproduce Steps
Now, modify
src/index.js
. It will run ESLint on all files (src/index.js
andsrc/render.js
), even iflintDirtyModulesOnly
is enabled inconfig.mjs
.The text was updated successfully, but these errors were encountered: