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
Add ESLint config for JavaScript Standard Style #2471
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
domoscargin
added
tooling
dependencies
Pull requests that update a dependency file
javascript
Pull requests that update Javascript code
labels
Dec 2, 2022
✅ You can preview this change here:
To edit notification comments on pull requests, go to your Netlify site settings. |
domoscargin
force-pushed
the
bk-eslint
branch
6 times, most recently
from
December 2, 2022 01:08
d95036a
to
49368d7
Compare
domoscargin
force-pushed
the
bk-eslint
branch
from
December 2, 2022 16:26
49368d7
to
d5394fc
Compare
colinrotherham
approved these changes
Dec 2, 2022
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.
Brill, all approved
I'll leave you to rebase for the conflict 😭
Following the guidance in the `eslint-config-standard` README.md https://github.com/standard/eslint-config-standard#readme.
Adds a main `.eslintrc.js` config file which extends `standard`, ignores relevant folders, and sets the test environment to jest on relevant files. Also adds an `.eslintrc.js` file in the `src` folder, to ignore `no-var`, `object-shorthand` and `quote-props` warnings.
This fix doesn't seem to break anything, though I'll admit it's straight off stackoverflow.
The `.eslintrc.js` was being copied to `public/deploy`.
domoscargin
force-pushed
the
bk-eslint
branch
from
December 5, 2022 08:35
d5394fc
to
e7525d1
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
dependencies
Pull requests that update a dependency file
javascript
Pull requests that update Javascript code
tooling
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based on the work in alphagov/govuk-frontend#2849
This PR upgrades
standard
from 12.0.1 to 17.0.0 (as attempted in #2439)In addition to allowing newer ES features without warnings and allowing IDEs to see issues visually whilst coding, this ignores the
no-var
,object-shorthand
andquote-props
warnings in thesrc
folder.We're also following the eslint-config-standard README.md and adding the following ESLint plugins: