Skip to content
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

fix: bring quote props rule inline with prettier config #101

Merged
merged 1 commit into from
Apr 29, 2021

Conversation

thomas-gordon
Copy link
Contributor

In order to get prettier and eslint not conflicting over quote-props;

https://github.com/ackama/prettier-config-ackama/blob/master/.prettierrc.json

The prettierrc specifies
"quoteProps": "consistent"

but the default eslint rule for quote-props is "always", which conflicts with the specification of the prettierrc. In order to match the suggested code style in prettierrc, we need to update the eslint to the matching config of 'consistent-as-needed'

@thomas-gordon thomas-gordon requested review from a team and G-Rath April 29, 2021 03:32
@G-Rath
Copy link
Contributor

G-Rath commented Apr 29, 2021

This seems like something that should be being handled by eslint-config-prettier as it's meant to be disabling eslint rules that prettier handles 🤔

I've not had eslint & prettier fight over this so far, and it's definitely come into play for repos with both - maybe something has changed somewhere.

(not against this change - it seems like the right thing to do, but just curious to why we've not come across this before)

@G-Rath
Copy link
Contributor

G-Rath commented Apr 29, 2021

Actually, this has to be being disabled by something currently, as we're clearly not quoting properties always (the file your editing has properties that eslint isn't flagging), so yeah, weird.

This change is definitely what we want 😅

@G-Rath G-Rath changed the title fix: Bring quote props rule inline with prettier config fix: bring quote props rule inline with prettier config Apr 29, 2021
@G-Rath G-Rath merged commit 98b448b into main Apr 29, 2021
@G-Rath G-Rath deleted the fix/eslint-quote-props branch April 29, 2021 03:54
github-actions bot pushed a commit that referenced this pull request Apr 29, 2021
## [2.1.2](v2.1.1...v2.1.2) (2021-04-29)

### Bug Fixes

* bring quote props rule inline with prettier config ([#101](#101)) ([98b448b](98b448b))
@github-actions
Copy link

🎉 This PR is included in version 2.1.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

G-Rath added a commit that referenced this pull request Aug 6, 2024
This reverts #101 which was never actually needed - for the most part
having it configured is harmless since it matches our prettier config
which in theory all of our codebases use, but if we ever have one that
has a different [quote
props](https://prettier.io/docs/en/options.html#quote-props) setting
(e.g. due to an inherited codebase) then you have to deal with this.

Removing it's configuration just means one less place to stub your toe
github-actions bot pushed a commit that referenced this pull request Aug 6, 2024
## [3.2.3](v3.2.2...v3.2.3) (2024-08-06)

### Bug Fixes

* let `prettier` handle `quote-props` ([#334](#334)) ([9eb3923](9eb3923)), closes [#101](#101)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants