I used the following plugin to install jslint for vim: https://github.com/hallettj/jslint.vim.
I’m a bit confused as to how to configure this.
I see a list of options here http://www.jslint.com/lint.html#options, but
- in the jslint-vim plugin, where do I specify these options?
- What is the option for removing indenting errors
- What is the option to remove the “x variable was used before it was defined?”
Create a .jslintrc in your home directory. The options are listed in a
/**/comment block. There’s an example in the documentation under Usage. Options set in your .jslintrc will apply to jslint generally, not just the vim plugin.Try setting
white: tolerate messy whitespace. But this will cause other issues to pass.Put this in your .jslintrc:
The option is named
undef. Put this in your .jslintrc:Putting those two options together: