Write json errors on console #12834
Description
Prerequisites
- Can you reproduce the problem with
Debug \ Reload Without Extensions
? - Did you perform a cursory search to see if your bug or enhancement is already reported?
- Did you read the Troubleshooting guide?
For more information on how to write a good bug report read here
For more information on how to contribute read here
Description
In #12831 I had a briefly discussion with @redmunds:
I think would be even better having a json linter in core.
I'm ok with that as long as user has a way to disable it.
While I'm the one that proposed the extension approach, actually I don't want another situation like the one with JSLint.
So I agree with @redmunds that if we add one we have to be careful in how we integrate it.
And more better our json files should not be strict json, they should support, for example, comments in them. Something like gyp file which support also trailing commas.
Totally agree.
Maybe trailing commas are too much, but comments IMHO are really needed.
But yes, as short gap would be nice printing something in the console in case of error.
While I agree, with both of those suggestions, they won't catch all cases, so errors should still be written to console.
We should check at least all json file used directly by Brackets core (brackets.json
, ...)
Steps to Reproduce
- Create a
.brackets.json
- Write an invalid json
- Open the Console of Developer Tools
Expected behavior:
A warning logged
Actual behavior:
Zero warning
Versions
Windows 10
master