Skip to content

Upgrade CodeClimate ESLint engine and resolve errors#3914

Merged
aduth merged 7 commits intomasterfrom
update/code-climate-eslint
Jul 14, 2020
Merged

Upgrade CodeClimate ESLint engine and resolve errors#3914
aduth merged 7 commits intomasterfrom
update/code-climate-eslint

Conversation

@aduth
Copy link
Contributor

@aduth aduth commented Jul 14, 2020

See #3909 (comment) for additional context.

By default, CodeClimate uses an older version of ESLint than is installed in the project. It was not adhering to the expected configuration, causing both false positives and false negatives. The changes in this pull request update CodeClimate to use a version of ESLint closer to that which is installed in the application. It includes fixes to all preexisting issues.

Issues were fixed by a combination of:

  • Running ESLint's automated fixer
    • npx eslint app spec --fix
  • Manual review:
    • Line length exceeded -> Break to new line
    • Reference to location global -> Reference from window global window.location
    • Circular dependency -> Disable the rule
      • This is something which should be fixed, will probably be redundant with future effort toward the doc auth flow, but which would require possible significant refactoring to address now. If it's working well enough as-is, it shouldn't be a problem to keep it.

For all specific changes, note that these rules are inherited largely from Airbnb's coding standard that we follow, and are therefore largely expected.

Copy link
Contributor

@zachmargolis zachmargolis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@aduth aduth force-pushed the update/code-climate-eslint branch from 158283d to 311a523 Compare July 14, 2020 18:12
@aduth aduth merged commit 748af83 into master Jul 14, 2020
@aduth aduth deleted the update/code-climate-eslint branch July 14, 2020 19:28
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

Successfully merging this pull request may close these issues.

2 participants