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
eslint throws if package.json is in UTF-8 with BOM #6556
Comments
This seems like it shouldn't throw. Unless JSON is very explicitly not allowed to be encoded in UTF8 with BOM, I think we should see if we can work around this. |
@vsemozhetbyt Can you read the file using nodejs UPDATE: |
@platinumazure NW.js has no problem with this JSON. I think this is not concerned JSON format by itself, but IO file preprocessing. @gyandeeps Should not Eslint strip BOM before calling |
Yeah. |
What version of ESLint are you using?
2.13.1
What parser (default, Babel-ESLint, etc.) are you using?
default
What did you do?...
I've checked a
.js
file in the NW.js project directory withpackage.json
in UTF-8 with BOM (there are no eslint settings in thispackage.json
).What did you expect to happen?
Output from eslint according to
.eslintrc.json
in some ancestor directory.What actually happened? Please include the actual, raw output from ESLint.
If I resave the
package.json
in UTF-8 without BOM, all is OK.The text was updated successfully, but these errors were encountered: