I'm using SublimeLintern package, but I'm experiencing some issues. I would like to toggle that "laxcomma" warning that appears each time I save my files: I do prefer putting my commas at the beginning of each row
{
"item1": val1
,"item2": val2
,"item3": val3
}
Hence, I tried to look for some piece of documentation that explained how to enable or disable each check. I bumped into this that should explain what I need.
So, my SublimeLinter.sublime-settings
is now like this:
{
"jshint_options": {
"laxcomma": false
}
}
but it doesn't seem to be working. I still see that bothering warning! What's wrong with my settings?
Bizarre. For me, the issue was that I had a .jshintrc
file in the local directory of my project. Despite the fact that laxcomma
wasn't being overridden there EITHER, apparently it just completely overrides your jshint_options (or maybe it does a top-level extend and doesn't recursively merge the config objects...)
The solution was to add (to the local .jshintrc
file):
"laxcomma": true
The word "lax" means not strict or severe; if you want to put your commas at the beginning of each line, try setting "laxcomma" to true:
{
"jshint_options": {
"laxcomma": true
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With