Skip to content

ESLint reports 1230 errors and 5 warnings #472

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

Closed
felbit opened this issue Sep 8, 2018 · 4 comments
Closed

ESLint reports 1230 errors and 5 warnings #472

felbit opened this issue Sep 8, 2018 · 4 comments

Comments

@felbit
Copy link
Contributor

felbit commented Sep 8, 2018

The readme suggests the use of npm run lint-test to "help you write quality JavaScript code by checking for common formatting errors, enforcing style rules, and suggesting changes that conform to best practices."

ESLint reports 1230 errors and 5 warnings.

This should be fixed.

lint-test-result.txt

@xarxziux
Copy link
Contributor

xarxziux commented Sep 9, 2018

I just ran my fork of the project through Codacy and it found 3,860 errors. However, a vast majority of them (2,497) is the error "Strings must use doublequote" which is odd since the ESLint check flagged up the error "Strings must use singlequote".

Many of these errors can be fixed by th--fix parameter for ESLint, or by adding the Prettier package to the repo. The first option is a relatively quick-win, but temporary. The second will probably be better in the long run, but is likely to require a lot of work initially. What's everyone's though on these?

@tejasbubane
Copy link
Member

tejasbubane commented Sep 10, 2018

Many of these errors can be fixed by th--fix parameter for ESLint, or by adding the Prettier package to the repo. The first option is a relatively quick-win, but temporary. The second will probably be better in the long run, but is likely to require a lot of work initially. What's everyone's though on these?

On the contrary I think the second one (prettier) should be easier to do since everything should be formatted in a single command. But we decided against using prettier long back #298

Eslint configuration is not complete (open issue #44) and is not added in CI. Hence all the errors. I am not sure if I have the time to look at each of those eslint rules and decide which ones to use. I would rather go with eslint:recommended or prettier, but I will keep the discussion open for others in @exercism/javascript

@xarxziux
Copy link
Contributor

Prettier or eslint --fix will take care of some of the formatting issues, which are the bulk of the errors, but not everything. It might be worth doing another eslint --fix and pulling the lot in one go.

@tejasbubane
Copy link
Member

This can now be closed in favor of #480

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants