-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ESLint errors fix #9091
ESLint errors fix #9091
Conversation
4e9b981
to
b8a1643
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don`t have practice to modify 3rd party libraries, for static test we have blacklist that exludes these files. Most of your fixes is in libraries. Can you please revert this changes?
Looks like I have to redo everything, but I have some concerns about your current blacklist and whitelist content. IMO it doesn't cover all of your custom code, that's why tests currently are passing.
Varien code also is your custom solution, but is blacklisted:
Also when we take a look on whitelist, few dirs are missing, i.e. we have
|
@Igloczek About blacklisted files(not 3rd party), we already have internal ticket to refactor these files, because most of them didn`t support strict mode. About files that you change, please, exclude these files:
Most of them not under Magento license. |
b841bcd
to
398e395
Compare
@omiroshnichenko I had to redo everything. I updated blacklist and whitelists to cover more files and clearly mark why some of them are blacklisted, b/c need serious refactoring. Also instead of blacklisting whole files, I added some ESLint and JSCS ignores inside files. BTW. JSCS has merged with ESLint, are you open to updates in this area? |
@Igloczek Looks good. About linters merging, I made small investigation about that and I think we can make update in nearest future. |
@Igloczek Thank you for the contribution |
It's part of #9089.
This PR contains only safe changes generated using
--fix
flag for ESLint.I manually excluded all of 3rd party code from
lib/web
, overwriting them after fixing process. Unfortunatly 3rd party code is mixed with Magento code withinlib/web
, so there isn't a quick way to use eslint against only custom code, without blacklisting 3rd party manually.Manual testing scenarios
yarn global add eslint
/npm install -g eslint
)eslint -c dev/tests/static/testsuite/Magento/Test/Js/_files/eslint/.eslintrc --fix lib/**/*.js
eslint -c dev/tests/static/testsuite/Magento/Test/Js/_files/eslint/.eslintrc --fix app/**/*.js