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
{{ message }}
This repository has been archived by the owner on Sep 28, 2020. It is now read-only.
This behaviour may actually be the intended behaviour, however if so:
it would be good to update the eslint-loader docs to make it clearer
it then seems that the failOnError option is actually redundant and could be removed? (since unlike failOnWarning, it's unable to actually override webpack's handling here)
The text was updated successfully, but these errors were encountered:
Here is what I just realized is the difference: Yes, npm will exit with code 2 regardless of how failOnError or failOnWarning are set. However, it does affect whether the module is marked as failing to build in the built bundle. If you have failOnError and failOnWarning both set to false, and you build and you have eslint errors and warnings, you will still be able to run your build. OTOH, if failOnError is true and you have eslint errors, the module will be marked as having failed to build in the built bundle, and the bundle will not run.
Hi
The docs for the failOnError option say:
This gives the impression that any ESLint errors will not cause the build to fail out of the box.
However this is not the case. eg:
yarn
yarn webpack --mode development
Expected:
Exit code of zero.
Actual:
The only way to get an exit code of zero is to set
emitWarning: true
.It looks like webpack's
emitError
now causes the compile to fail (perhaps it didn't in older webpack?), here:eslint-loader/index.js
Line 128 in f9d48ea
This behaviour may actually be the intended behaviour, however if so:
failOnError
option is actually redundant and could be removed? (since unlikefailOnWarning
, it's unable to actually override webpack's handling here)The text was updated successfully, but these errors were encountered: