-
-
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
Shoudn't format file when only prettier can process file #68
Comments
Hmmmmm... Are you sure that's what's happening? If you look at the source code, you'll see that it throws an error if prettier or eslint fail. If it is a problem, feel free to open a pull request to fix it. Thanks! |
I'm sure only about the result, maybe it happens because of some other reason |
Any chance you could make a repo that reproduces the issue? |
It's no longer an issue for me, I ended up configuring babel-eslint parser so any syntax babel recognizes is possible. You might consider the same for prettier-eslint-cli: sheerun/prettier-standard@eea070e |
Thanks for sharing. I think it's not an issue for prettier-eslint because people configure ESLint with the parser that works for their code. So if they're using ESNext code that ESLint doesn't support, they'll specify they want to use the babel-eslint parser and that's what we'll use. Cheers. |
If file has non-standard syntax, like class properties, prettier-eslint passes source through prettier but silently skips transforming through eslint. This behavior makes file to be formatted with default prettier settings, while the expected behavior is leaving file intact.
Example file:
if you format this with prettier-eslint rules set to
the jsx is formatted to double quotes
The text was updated successfully, but these errors were encountered: