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

Should not overwrite buffer when prettier fails to parse file #2

Closed
mitermayer opened this issue May 26, 2017 · 0 comments · Fixed by #3
Closed

Should not overwrite buffer when prettier fails to parse file #2

mitermayer opened this issue May 26, 2017 · 0 comments · Fixed by #3
Assignees
Labels

Comments

@mitermayer
Copy link
Member

At the moment if we have an invalid file like this we are still overwriting the buffer with the prettier error output.

// @format
const foo x= (a, b) => {};

becomes

stdin: SyntaxError: Unexpected identifier (2:10)
  1 | // @format
> 2 | const foo x= (a, b) => {};
    |           ^
  3 | 

Expected behaviour:

Not overwrite buffer and display an error message

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 a pull request may close this issue.

1 participant