-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
Run ESLint over our JS files, fix all lints #50172
Conversation
I'm still waiting on guidance as to the copyright comments, but regardless I think this is a good change as it fixes a load of lint problems and type errors in our scripts. |
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.
Seems fine. How long does it take?
That's a great question. It's 4x faster for some reason, which then made me notice that the gulp task is not working properly without the flag because eslint doesn't scan anything other than |
Hm, no, ts-eslint's config doesn't do this. I don't know who does; if use ESLint on my own projects, it does the right thing, but it does the wrong thing on the TS repo. |
The reality is weirder; apparently the ESLint CLI will look at |
So, to re-answer with the fix, the new lint time is maybe about 1s longer than the old one, give or take, but it's already a 40s run uncached. Cached, it's about 3s on my machine before/after. |
In prep for adding copyright headers to all of our source files, make our lint task run ESLint on our JS files too (which will need the headers, and I want ESLint to enforce that).
Our
.eslintignore
already covers ignoring the js files we don't care about, e.g. build artifacts and baselines.