-
-
Notifications
You must be signed in to change notification settings - Fork 171
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
Prettier does not respect the "no-multiple-empty-lines" rule of eslint #176
Comments
This is not possible as the output eslint gets is already ran though prettier. The only way to get the outcome you're after is to add an option about this in prettier. |
Yes I'm looking for an option in Prettier for this, but cannot see any here: https://prettier.io/docs/en/options.html. |
I'm thinking that for your case if you really don't want the prettier way of formatting then maybe it's just better for you to go with using eslint only. |
Prettier rocks... I want two spaces between my functions and classes... please!!! |
We can't do anything about this until prettier changes its formatting or add an option to allow multiple empty lines. Eslint isn't powerful enough to revert all formatting that prettier imposes. |
Yeah, sometimes I like to add two empty lines for better code readability, but prettier is leaving only one line there after formatting. Would be nice to have configurable option for this. |
Why do they decide for us what will be more beautiful for our project? |
Yes, I make my code much more readable using multiple empty lines! Why ignoring such an important thing, so much user asking for? |
Complain helps nothing. |
Prettier removes any multiple empty lines collapsing to max 1 empty line.
I understand the default behavior but I would like to override it with eslint
Example with my rule (google/airbnb style guide):
"no-multiple-empty-lines": ["error", { "max": 2 }]
Becomes:
Opinionated behavior should only be the default and should be configurable.
Ref: prettier/prettier#1613
The text was updated successfully, but these errors were encountered: